Jakub Konka
310aa87198
Fix alignment issue
2020-08-07 23:21:06 +02:00
Jakub Konka
bdda8fa7a8
Redo GetFinalPathNameByHandle using DeviceIoControl
...
This commit reimagines `std.os.windows.GetFinalPathNameByHandle`
using `DeviceIoControl` to query the OS mount manager for the DOS
(symlink) paths for the given NT volume name. In particular,
it uses `IOCTL_MOUNTMGR_QUERY_POINTS` ioctl opcode to query the
manager for the available moount points.
2020-08-07 11:33:05 +02:00
Jakub Konka
e8abfef2aa
Add docs
2020-08-06 23:56:37 +02:00
Jakub Konka
2628a8846e
Use NtQueryInformationFile unless unavailable
...
Favour newer API which uses `NtQueryInformationFile` with class flags
`FileNormalizedNameInformation` and `FileVolumeNameInformation`
instead of lower-level `NtQueryObject`. `NtQueryObject` is still
used as a fallback in case the former are unavailable.
2020-08-06 23:56:37 +02:00
Jakub Konka
747d46f22c
Initial draft of GetFinalPathNameByHandle
...
This commit proposes an initial draft of `GetPathNameByHandle` function
which wraps NT syscalls and strives to emulate (currently only
partially) the `kernel32.GetFinalPathNameByHandleW` function.
2020-08-06 23:56:37 +02:00
Andrew Kelley
a2bb246db4
Revert "std.fmt.format: small optimization to avoid runtime bloat"
...
This reverts commit 11d38a7e520f485206b7b010f64127d864194e4c.
The benefits of this commit are not enough to justify the compromise
that it made.
closes #5977
2020-08-05 13:30:43 -07:00
Andrew Kelley
c4b9f5e52f
Merge branch 'pixelherodev-elf-refactor'
...
closes #5976
2020-08-05 11:27:37 -07:00
Noam Preil
a85452b2c2
Codegen: 16-bit pointers
2020-08-05 11:25:43 -07:00
Noam Preil
a5b76d2474
Stage2: minor File.ELF refactor
2020-08-05 11:25:08 -07:00
Andrew Kelley
cf4936bcb0
std.os tests: improve robustness of "symlink with relative paths"
2020-08-04 23:45:53 -07:00
Andrew Kelley
d159ba9295
zig fmt
2020-08-04 23:04:20 -07:00
Andrew Kelley
f23fb3087b
zig build: fix addBuildOption for []const u8 and ?[]const u8
2020-08-04 22:55:45 -07:00
Andrew Kelley
2139697ce5
zig build: fix addBuildOption for []const u8 and ?[]const u8
2020-08-04 22:54:59 -07:00
Andrew Kelley
316b4bde6a
update target CPU features from llvm 10 to 11rc1
2020-08-04 21:46:49 -07:00
Andrew Kelley
8824491fc7
stage2: add missing newlines to cli error messages
2020-08-04 18:38:42 -07:00
Andrew Kelley
e2b9e2137e
update clang command line options data from 10 to 11rc1
2020-08-04 18:03:04 -07:00
Andrew Kelley
4269868d6a
update install files for LLVM 11rc1
2020-08-04 17:52:26 -07:00
Andrew Kelley
372062b4fe
libunwind: update from LLVM 10 to 11rc1
2020-08-04 17:39:29 -07:00
Andrew Kelley
42da1d385d
libcxxabi: upgrade from llvm 10 to 11rc1
2020-08-04 17:30:57 -07:00
Andrew Kelley
54b67c2025
libcxx: update from LLVM 10 to 11rc1
2020-08-04 17:26:02 -07:00
Andrew Kelley
16513fee6c
update C lib/include/ files from clang 10 to 11rc1
2020-08-04 17:17:48 -07:00
Andrew Kelley
c6e0df6213
Merge remote-tracking branch 'origin/master' into llvm11
2020-08-04 17:09:40 -07:00
Andrew Kelley
d61a9e37ae
stage2 tests: fix qemu logic
...
I made two mistakes in the previous commit; it was not actually using
the argv that we built, and also the qemu logic was unconditionally
skipping the test.
Now I have verified that when mangling the RISC-V "hello world" test and
then using -Denable-qemu, we get a test failure.
2020-08-04 15:39:59 -07:00
Andrew Kelley
e4eb4396c2
Merge branch 'pfgithub-stage2-testing-Copy-2'
2020-08-04 15:32:41 -07:00
Andrew Kelley
c594f8dc26
stage2 tests: support the -Denable-qemu options and friends
2020-08-04 15:32:16 -07:00
Andrew Kelley
02d09d1328
codegen: introduce toCanonicalReg to clean up x86-specific logic
2020-08-04 15:31:54 -07:00
pfg
ea3cc777cc
stage2: riscv test case
2020-08-04 14:38:33 -07:00
pfg
e3352db986
stage2: riscv correctly aligned functions
2020-08-04 14:38:33 -07:00
pfg
0b53a2d996
stage2: riscv 0 argument non-nested function calls
2020-08-04 14:38:33 -07:00
pfg
1fd99ed324
stage2: riscv hello world
2020-08-04 14:38:33 -07:00
pfg
52ae2b10aa
stage2: starting on a riscv64 backend
2020-08-04 14:38:33 -07:00
Andrew Kelley
952a397b0e
Merge pull request #5978 from ziglang/stage2-dwarf-incr
...
self-hosted: line number debug information
2020-08-04 20:53:47 +00:00
Andrew Kelley
331f6a07a9
stage2: fix ZIR support and C back end
2020-08-04 12:15:47 -07:00
Andrew Kelley
b7a883b7d1
stage2: link: fix not freeing debug line free list
2020-08-04 12:15:47 -07:00
Andrew Kelley
ca19c42b74
stage2: fix updating debug line info not resizing properly
2020-08-04 12:15:47 -07:00
Andrew Kelley
7d70774fde
stage2: fix memory leak with exported decl name
2020-08-04 12:15:47 -07:00
Andrew Kelley
0d696a48da
stage2 .debug_line: handle Decl line numbers changing
2020-08-04 00:22:11 -07:00
Andrew Kelley
30ee08dfc2
stage2: stop needlessly re-analyzing unchanged functions
2020-08-03 23:47:54 -07:00
Andrew Kelley
cb25d8e4bc
stage2 .debug_line: handle Decl deletes and updates
2020-08-03 23:13:54 -07:00
Andrew Kelley
9b3a70c8aa
stage2: move link.File.ELF.SrcFn field from Module.Fn to Module.Decl
...
SrcFn represents the function in the linked output file, if the
`Decl` is a function. This is stored here and not in `Fn` because `Decl`
survives across updates but `Fn` does not.
TODO Look into making `Fn` a longer lived structure and moving this field there
to save on memory usage.
2020-08-03 22:22:47 -07:00
Andrew Kelley
0c598100d8
stage2: fix use-after-free of export symbol name
2020-08-03 22:07:21 -07:00
Andrew Kelley
edfede575c
self-hosted: add build option for log scopes
...
Now you can enable a set of log scopes by passing -Dlog=<scope>
2020-08-03 21:56:21 -07:00
Andrew Kelley
a33efc74ed
stage2 codegen: revert the unneeded is_stmt stuff
2020-08-03 21:09:58 -07:00
Andrew Kelley
d624bf8059
stage2 .debug_line stepping with gdb is working
2020-08-03 21:01:06 -07:00
Andrew Kelley
ac10841fa9
stage2 .debug_line: simpler strategy for incremental compilation
...
See #5963
2020-08-03 19:14:09 -07:00
Vexu
4ab2f947f9
translate-c: recognize other type trait expressions
...
Closes #5979
2020-08-04 00:48:29 +03:00
Andrew Kelley
4e023c6fa8
stage2: dwarf: fix standard opcode length of LNS_fixed_advance_pc
2020-08-03 00:54:30 -07:00
Andrew Kelley
eccbb03063
downgrade .debug_info to DWARFv4
...
gdb, notice me senpai
2020-08-03 00:42:08 -07:00
Andrew Kelley
bf85d3db3f
downgrade .debug_line to DWARFv4
...
apparently gdb 8.3.1 which is still a commonly distributed version of gdb,
does not support v5.
2020-08-03 00:34:12 -07:00
Andrew Kelley
659603c621
codegen: emit .debug_line ops for IR instructions
2020-08-02 21:28:06 -07:00