Page MenuHomePhabricator

dschuff (Derek Schuff)
Yet Another Compiler Compiler

Projects

User does not belong to any projects.

User Details

User Since
Jan 7 2013, 9:35 AM (441 w, 8 h)

US-Pacific timezone.

Recent Activity

Thu, Jun 17

dschuff accepted D104495: [lld][WebAssembly] Fix crash calling weakly undefined function in PIC code.
Thu, Jun 17, 5:08 PM · Restricted Project
dschuff accepted D103290: [lld][WebAssembly] Add new `--import-undefined` option.
Thu, Jun 17, 11:40 AM · Restricted Project

Tue, Jun 1

dschuff accepted D103486: [lld][WebAssemlby] Fix for string merging of -dwarf-5 sections.
Tue, Jun 1, 2:30 PM · Restricted Project

Wed, May 26

dschuff added a comment to D103181: [SimplifyCFG] Use make_early_inc_range() while deleting instructions.

nice small reproducer too.

Wed, May 26, 9:57 AM · Restricted Project
dschuff accepted D103181: [SimplifyCFG] Use make_early_inc_range() while deleting instructions.

Looks straightforward, thanks for tracking this down.

Wed, May 26, 9:57 AM · Restricted Project

Mon, May 24

dschuff added inline comments to D102978: [WebAssembly] Add TargetInstrInfo::getCalleeOperand.
Mon, May 24, 5:00 PM · debug-info, Restricted Project
dschuff accepted D102978: [WebAssembly] Add TargetInstrInfo::getCalleeOperand.

I think this makes sense.

Mon, May 24, 11:33 AM · debug-info, Restricted Project
dschuff accepted D102999: [WebAssembly] Add NullifyDebugValueLists pass.
Mon, May 24, 9:06 AM · Restricted Project

May 21 2021

dschuff accepted D102937: [lld][WebAssembly] Fix for PIC output + TLS + non-shared-memory.
May 21 2021, 2:19 PM · Restricted Project
dschuff added inline comments to D102937: [lld][WebAssembly] Fix for PIC output + TLS + non-shared-memory.
May 21 2021, 2:17 PM · Restricted Project
dschuff added a comment to D102937: [lld][WebAssembly] Fix for PIC output + TLS + non-shared-memory.

Ah, got it. So is it the case that we have e.g. a single .tdata section that might be separate now, but just 1 or 2 and not scaling with the size of the program.
Mostly I just want to make sure we don't slow down loading too much, especially in the dylib case where it will already be slower than the non-library case.

May 21 2021, 1:58 PM · Restricted Project
dschuff added a comment to D102937: [lld][WebAssembly] Fix for PIC output + TLS + non-shared-memory.

Does avoiding combing data segments in shared-memory mode mean that there will have to be a lot more passive segment initializations run at load time, instead of just one before?

May 21 2021, 11:13 AM · Restricted Project

May 20 2021

dschuff accepted D102791: [WebAssembly] Warn on exception spec for Emscripten EH.

Got it, this makes sense to me too. And since it can be turned off, I'm not too worried about annoying users.

May 20 2021, 11:33 AM · Restricted Project

May 19 2021

dschuff added a comment to D102791: [WebAssembly] Warn on exception spec for Emscripten EH.

BTW Is there a way to disable this warning?
Since IIUC this could cause code that was not warning (because it used -fno-exceptions or used emscripten's default of -fignore-exceptions) to now start warning, sometimes that makes users who use -Werror unhappy.

May 19 2021, 3:50 PM · Restricted Project
dschuff accepted D102795: [WebAssembly] Ignore filters in Emscripten EH landingpads.
May 19 2021, 3:42 PM · Restricted Project
dschuff accepted D102806: [lld][WebAssembly] Fix for string tail merging and -r/--relocatable.
May 19 2021, 3:22 PM · Restricted Project

May 18 2021

dschuff committed rG5f2b27666797: Default stack alignment of x86 NaCl to 16 bytes (authored by fabiansommer).
Default stack alignment of x86 NaCl to 16 bytes
May 18 2021, 3:18 PM
dschuff closed D102610: Default stack alignment of x86 NaCl to 16 bytes.
May 18 2021, 3:17 PM · Restricted Project
dschuff accepted D102704: [lld][WebAssembly] Convert test to assembly. NFC..
May 18 2021, 11:59 AM · Restricted Project
dschuff accepted D102436: [lld][WebAssembly] Enable string merging for debug sections.
May 18 2021, 11:52 AM · Restricted Project

May 17 2021

dschuff added a comment to D102610: Default stack alignment of x86 NaCl to 16 bytes.

(do you want me to land this?)

May 17 2021, 6:10 PM · Restricted Project
dschuff accepted D102610: Default stack alignment of x86 NaCl to 16 bytes.
May 17 2021, 6:10 PM · Restricted Project
dschuff added inline comments to D102436: [lld][WebAssembly] Enable string merging for debug sections.
May 17 2021, 6:09 PM · Restricted Project
dschuff accepted D102546: [lld][WebAssembly] Refactor input chunk class hierarchy. NFC.
May 17 2021, 5:53 PM · Restricted Project
dschuff added inline comments to D102546: [lld][WebAssembly] Refactor input chunk class hierarchy. NFC.
May 17 2021, 5:07 PM · Restricted Project
dschuff added a comment to D102589: [WebAssembly] Nullify DBG_VALUE_LISTs in DebugValueManager.

Until recently, variable locations that could not be described became "DBG_VALUE $noreg" instructions. With some recent patches from @StephenTozer , some of those locations can now be described with DBG_VALUE_LIST instructions. If I understand this patch correctly, for WebAssembly those DBG_VALUE_LIST instructions transition back to being "DBG_VALUE $noreg". There should be no regression in variable location coverage: instead, WebAssembly does not yet benefit from the additional locations now being recovered.

May 17 2021, 11:33 AM · Restricted Project
dschuff accepted D102589: [WebAssembly] Nullify DBG_VALUE_LISTs in DebugValueManager.

If I'm understanding this correctly, we only create a WebAssemblyDebugValueManager object when we actually stackify a reg and move the def, correct?
I guess that still ends up invalidating a lot of debug info, since we always run explicit locals.
In the code you've seen, does the debug info all or mostly consist of DBG_VALUE_LISTs now, or is it still mostly DBG_VALUE, or a mix?
I'm just trying to get a sense for how much of a degradation in debug info quality we have now.
(Not that we shouldn't do this; clearly this is better than the loop-explosion we have now. I'm just trying to get a sense for how urgent the "real" fix is).

May 17 2021, 9:24 AM · Restricted Project

May 12 2021

dschuff accepted D102309: [WebAssembly] Omit DBG_VALUE after terminator.
May 12 2021, 11:35 AM · Restricted Project

May 11 2021

dschuff accepted D102281: [lld][WebAssembly] Allow data symbols to extend past end of segment.
May 11 2021, 6:17 PM · Restricted Project
dschuff added inline comments to D102281: [lld][WebAssembly] Allow data symbols to extend past end of segment.
May 11 2021, 5:57 PM · Restricted Project
dschuff added a comment to D102281: [lld][WebAssembly] Allow data symbols to extend past end of segment.

I'm not sure I understand what the description means, in particular how null-termination is related to the symbol extending past the end of the segment. (more generally I guess I don't understand why we want to allow symbols to extend past the end).

May 11 2021, 5:06 PM · Restricted Project
dschuff accepted D102271: [lld][WebAssembly] Fix for string merging + negative addends.
May 11 2021, 4:59 PM · Restricted Project
dschuff accepted D102265: [lld][WebAssembly] Remove relocation target verification.
May 11 2021, 11:34 AM · Restricted Project
dschuff accepted D102264: [lld][WebAssembly] Convert test to assembly. NFC..
May 11 2021, 11:33 AM · Restricted Project

May 10 2021

dschuff accepted D102202: [WebAssembly] Add TLS data segment flag: WASM_SEG_FLAG_TLS.
May 10 2021, 4:47 PM · Restricted Project
dschuff added a comment to D102044: [lld][WebAssembly] Disallow exporting of TLS symbols.

thanks, still LGTM

May 10 2021, 9:48 AM · Restricted Project

May 7 2021

dschuff accepted D101784: [WebAssembly] Fix PIC/GOT codegen for wasm64.
May 7 2021, 10:46 AM · Restricted Project
dschuff accepted D102044: [lld][WebAssembly] Disallow exporting of TLS symbols.
May 7 2021, 9:37 AM · Restricted Project

May 4 2021

dschuff added a comment to D101736: [WebAssembly] Allow DBG_VALUE after terminator in MachineVerifier.

Thanks, interesting about DbgEntityHistoryCalculator, I saw it but thought that it was just part of the way the translation from dbg_values to DWARF/other debuginfo was done in the platform-independent code. And to be clear, our debug info generation appears to actually be working correctly; it's only the MachineVerifier that is complaining.
I'll take a closer look at DbgEntityHistoryCalculator

May 4 2021, 2:57 PM · Restricted Project
dschuff added inline comments to D101736: [WebAssembly] Allow DBG_VALUE after terminator in MachineVerifier.
May 4 2021, 2:54 PM · Restricted Project

May 3 2021

dschuff accepted D101716: [lld][WebAssembly] Fix crash with `-pie` without `--allow-undefined`.
May 3 2021, 5:07 PM · Restricted Project
dschuff accepted D101711: [lld][WebAssembly] Convert more tests to asm format.
May 3 2021, 5:07 PM · Restricted Project
dschuff added a comment to D101736: [WebAssembly] Allow DBG_VALUE after terminator in MachineVerifier.

Is throw also a terminator?

May 3 2021, 3:31 PM · Restricted Project
dschuff added a comment to D101716: [lld][WebAssembly] Fix crash with `-pie` without `--allow-undefined`.

So this change means that unresolved symbols will turn into imports when linking?

May 3 2021, 3:25 PM · Restricted Project
dschuff added inline comments to D101711: [lld][WebAssembly] Convert more tests to asm format.
May 3 2021, 2:52 PM · Restricted Project
dschuff accepted D97657: [lld][WebAssembly] Initial support merging string data.

I think this is pretty much ok now, other than that I would like to make it more clear exactly which parts are more-or-less directly copied from ELF; that way if we need to understand more in the future, we know where to look (and also if there are changes to ELF in the future we would know to look at those to see if they make sense for us too)

May 3 2021, 2:38 PM · Restricted Project
dschuff accepted D101703: [lld][WebAssembly] Do not merge comdat data segments.
May 3 2021, 1:59 PM · Restricted Project

Apr 30 2021

dschuff added a comment to D101656: [WebAssembly] Fixup order of ins variables for table instructions.

I think all of emscripten's use of the table is still via the JS API (e.g. src/runtime_functions.js) so this probably won't break emscripten. It does seem likely that nobody is using these instructions via assembly.
Is this the only change needed? Do we have no tests of these asm instructions anywhere in LLVM at all?

Apr 30 2021, 3:00 PM · Restricted Project
dschuff added a comment to D97657: [lld][WebAssembly] Initial support merging string data.

I think I'm generally fine with keeping things that are direct copies from ELF, although it would be nice if it were even easier to tell which pieces those are (there is one comment in a header; is it just that function though?)

Apr 30 2021, 11:51 AM · Restricted Project

Apr 29 2021

dschuff added a comment to D97657: [lld][WebAssembly] Initial support merging string data.

looks pretty good overall, a lot of this is making sure I understand everything

Apr 29 2021, 5:38 PM · Restricted Project
dschuff added a comment to D97657: [lld][WebAssembly] Initial support merging string data.

Still looking over this, but had a question more up front

Apr 29 2021, 4:28 PM · Restricted Project
dschuff accepted D99887: [lld][WebAssembly] Add `--export-if-defined`.
Apr 29 2021, 10:51 AM · Restricted Project

Apr 27 2021

dschuff accepted D101399: [lld][WebAssembly] Allow relocations against non-live global symbols.
Apr 27 2021, 4:41 PM · Restricted Project

Apr 26 2021

dschuff added a comment to D101271: [lld][WebAssembly] Add support for `--export-dynamic-symbol`.

LGTM modulo MaskRay's comment about the help text. Also I think @sunfish had a question earlier today that we didn't get to talk about.

Apr 26 2021, 2:44 PM · Restricted Project

Apr 23 2021

dschuff accepted D101112: [WebAssembly] Finalize wasm_simd128.h intrinsics.
Apr 23 2021, 1:24 PM · Restricted Project
dschuff added inline comments to D101112: [WebAssembly] Finalize wasm_simd128.h intrinsics.
Apr 23 2021, 10:42 AM · Restricted Project

Apr 22 2021

dschuff added inline comments to D101112: [WebAssembly] Finalize wasm_simd128.h intrinsics.
Apr 22 2021, 3:17 PM · Restricted Project
dschuff added a comment to D100981: Delete le32/le64 targets.

Would it make sense for you to to upstream an LLVM target such as le32-halide? (Or perhaps even arm32-halide or some other?) Then you'd actually have more control over your own codegen, datalayout, etc.

Apr 22 2021, 10:32 AM · Restricted Project, Restricted Project

Apr 21 2021

dschuff accepted D100981: Delete le32/le64 targets.

Thanks. I had heard in the past that there were some other folks who had used le32/le64 as a "generic" target (in fact that's why it's named so generically, rather than being called "pnacl" or similar) but I haven't heard of anything recently, and as you can see nobody has upstreamed any support for other OS or target specializations or asked to collaborate on it. Practically speaking even a target that wants fairly generic bitcode would probably want its own triple, so unless this removal captures someone's attention who wants to keep maintaining it, this should be fine to remove.

Apr 21 2021, 5:15 PM · Restricted Project, Restricted Project
dschuff accepted D100995: [WebAssembly] Put utility functions in Utils directory (NFC).

This looks good. Since you've created new build components, don't forget to test the LLVM/clang build and make sure it works with static libraries and with the LLVM dylib before you land.

Apr 21 2021, 2:21 PM · Restricted Project

Apr 20 2021

dschuff added inline comments to D100888: [WebAssembly] Update README. NFC..
Apr 20 2021, 1:58 PM · Restricted Project
dschuff accepted D100888: [WebAssembly] Update README. NFC..
Apr 20 2021, 1:57 PM · Restricted Project
dschuff accepted D100887: [WebAssembly] Remove unused known_gcc_test_failures.txt. NFC.
Apr 20 2021, 1:55 PM · Restricted Project

Apr 7 2021

dschuff accepted D100018: [WebAssembly] Add shuffles as an option for lowering BUILD_VECTOR.

Otherwise the code looks good though

Apr 7 2021, 5:16 PM · Restricted Project
dschuff added inline comments to D100018: [WebAssembly] Add shuffles as an option for lowering BUILD_VECTOR.
Apr 7 2021, 5:10 PM · Restricted Project

Apr 5 2021

dschuff added a comment to D99887: [lld][WebAssembly] Add `--export-if-defined`.

Oh also, I think --export-if-defined is an OK name.

Apr 5 2021, 2:07 PM · Restricted Project
dschuff added a comment to D99887: [lld][WebAssembly] Add `--export-if-defined`.

Pre-existing, but what does --export plus --allow-undefined do?

Apr 5 2021, 2:07 PM · Restricted Project
dschuff accepted D99885: [lld][WebAssembly] Rewrite exports test in assembly. NFC.
Apr 5 2021, 10:18 AM · Restricted Project

Mar 31 2021

dschuff accepted D99644: [WebAssembly] Raname a test and fix comments.
Mar 31 2021, 8:49 AM · Restricted Project

Mar 30 2021

dschuff accepted D99623: [WebAssembly] Implement i64x2 comparisons.
Mar 30 2021, 4:30 PM · Restricted Project, Restricted Project
dschuff accepted D99627: [WebAssembly] Encode numbers in ULEB128 in event section.
Mar 30 2021, 4:13 PM · Restricted Project

Mar 29 2021

dschuff accepted D99536: [WebAssembly] Fix i8x16.popcnt opcode.
Mar 29 2021, 3:37 PM · Restricted Project

Mar 12 2021

dschuff accepted D98466: [WebAssembly] Remove experimental SIMD instructions.
Mar 12 2021, 11:18 AM · Restricted Project, Restricted Project
dschuff accepted D98457: [WebAssembly] Remove unimplemented-simd target features.
Mar 12 2021, 11:15 AM · Restricted Project, Restricted Project

Mar 4 2021

dschuff added inline comments to D97929: [WebAssembly] Fix ExceptionInfo grouping again.
Mar 4 2021, 3:14 PM · Restricted Project
dschuff accepted D97929: [WebAssembly] Fix ExceptionInfo grouping again.

LGTM assuming the test is what you intended.

Mar 4 2021, 11:18 AM · Restricted Project
dschuff added inline comments to D97929: [WebAssembly] Fix ExceptionInfo grouping again.
Mar 4 2021, 9:55 AM · Restricted Project

Mar 3 2021

dschuff accepted D97834: [WebAssembly] Disable uses of __clang_call_terminate.

I agree this is a good approach, and I also like that it's smaller and simpler. In the future we can revisit whether following this particular Itanium convention buys us anything useful or not.

Mar 3 2021, 11:40 AM · Restricted Project, Restricted Project

Mar 1 2021

dschuff accepted D97651: [lld][WebAssembly] Convert lld/test/wasm/data-layout.ll to asm. NFC..
Mar 1 2021, 4:09 PM · Restricted Project
dschuff accepted D97654: [lld][WebAssembly] Minor refactor in preparation for SHF_STRINGS supports. NFC..
Mar 1 2021, 3:17 PM · Restricted Project
dschuff accepted D97677: [WebAssembly] Fix more ExceptionInfo grouping bugs.
Mar 1 2021, 2:41 PM · Restricted Project

Feb 26 2021

dschuff accepted D97595: [lld][WebAssembly] Rename methods/members to match ELF backend. NFC..
Feb 26 2021, 4:56 PM · Restricted Project
dschuff accepted D97583: [WebAssembly] Fix reverse mapping in WasmEHFuncInfo.

LGTM. since the data structure is a SmallPtrSet now, it probably makes sense to update the description and maybe the var names to reflect that.

Feb 26 2021, 3:39 PM · Restricted Project
dschuff accepted D97569: [WebAssembly] Fix remapping branch dests in fixCatchUnwindMismatches.
Feb 26 2021, 1:19 PM · Restricted Project
dschuff added inline comments to D97564: [WebAssembly] Fix split-dwarf not emitting DW_OP_WASM_location correctly.
Feb 26 2021, 1:16 PM · Restricted Project
dschuff accepted D97564: [WebAssembly] Fix split-dwarf not emitting DW_OP_WASM_location correctly.

otherwise LGTM

Feb 26 2021, 1:13 PM · Restricted Project
dschuff added a comment to D97564: [WebAssembly] Fix split-dwarf not emitting DW_OP_WASM_location correctly.

Would it make sense to also run e.g. llvm/test/MC/WebAssembly/debug-localvar.ll with split-dwarf?

Feb 26 2021, 11:33 AM · Restricted Project

Feb 23 2021

dschuff added a comment to D97247: [WebAssembly] Fix incorrect grouping and sorting of exceptions.

The description is great, and I think this change is the right thing to do for now. Once things stabilize, it might eventually make sense to think some more about how we might simplify the sorting algorithm (as you discussed in the description). And you're right that we'd want to have better performance/benchmarking in place to inform that.

Feb 23 2021, 11:58 AM · Restricted Project
dschuff accepted D97247: [WebAssembly] Fix incorrect grouping and sorting of exceptions.
Feb 23 2021, 11:52 AM · Restricted Project

Feb 22 2021

dschuff accepted D97178: [WebAssembly] Remap branch dests after fixCatchUnwindMismatches.
Feb 22 2021, 12:56 PM · Restricted Project
dschuff accepted D97175: [WebAssembly] Split EH MIR tests into two files.
Feb 22 2021, 10:15 AM · Restricted Project
dschuff accepted D97174: [WebAssembly] Support WasmEHFuncInfo serialization.
Feb 22 2021, 10:07 AM · Restricted Project
dschuff accepted D97173: [WebAssembly] Rename methods in WasmEHFuncInfo (NFC).
Feb 22 2021, 10:01 AM · Restricted Project

Feb 18 2021

dschuff accepted D96970: [WebAssembly] Handle multiple EH_LABELs in EH pad.
Feb 18 2021, 10:06 AM · Restricted Project

Feb 17 2021

dschuff accepted D96903: [WebAssembly] Remove dependency of reference types from EH.
Feb 17 2021, 3:35 PM · Restricted Project
dschuff committed rG1f9e551a811a: [WebAssembly] Do not use EHCatchret symbols with wasm EH (authored by dschuff).
[WebAssembly] Do not use EHCatchret symbols with wasm EH
Feb 17 2021, 11:23 AM
dschuff closed D96824: [WebAssembly] Do not use EHCatchret symbols with wasm EH.
Feb 17 2021, 11:23 AM · Restricted Project
dschuff updated the diff for D96824: [WebAssembly] Do not use EHCatchret symbols with wasm EH.

fix diff

Feb 17 2021, 11:06 AM · Restricted Project
dschuff updated the diff for D96824: [WebAssembly] Do not use EHCatchret symbols with wasm EH.

Update existing test instead of using new one

Feb 17 2021, 11:05 AM · Restricted Project
dschuff added a comment to D96824: [WebAssembly] Do not use EHCatchret symbols with wasm EH.

Ah, you are right, I initially thought that we needed a new test because none of ours failed when their patch went in. But the reason for that was that the output is all assembly rather than object files.
I added --implicit-check-not to exception.ll and that does catch the error.

Feb 17 2021, 11:04 AM · Restricted Project