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 (349 w, 6 d)

US-Pacific timezone.

Recent Activity

Tue, Sep 17

dschuff added inline comments to D67676: [lld][WebAssembly] Fix use after free of archive path.
Tue, Sep 17, 1:18 PM · Restricted Project

Thu, Sep 12

dschuff added inline comments to D67525: [WIP] Add WASM_TABLE_INDEX_{SLEB,I32} reloc types with addends.
Thu, Sep 12, 2:59 PM · Restricted Project
dschuff created D67525: [WIP] Add WASM_TABLE_INDEX_{SLEB,I32} reloc types with addends.
Thu, Sep 12, 2:55 PM · Restricted Project

Thu, Sep 5

dschuff added a comment to D67208: [WebAssembly] Add -fwasm-exceptions for wasm EH.

Oh, you're right, I'm conflating -mexception-handling with -fexceptions. And also -fno-exceptions with noexcept. So... just forget I was here

Thu, Sep 5, 4:55 PM · Restricted Project, Restricted Project
dschuff added a comment to D67208: [WebAssembly] Add -fwasm-exceptions for wasm EH.

If this is to be like -fdwarf-exceptions I assume the idea is that eventually it will default on when targeting wasm, and become one of those flags that most users never set. In that case it really just selects the default exception model, and thus it should be compatible with -fno-exceptions just as -fdwarf-exceptions.
Also -fno-exceptions doesn't really mean "no exceptions whatsoever" because if you call something that the compiler isn't sure never throws, it generates an implicit catch-all that calls std::terminate. So how it does that would still be affected by the exception model. (and whatever downstream invoke-removing pass or postprocessing tool might care).

Thu, Sep 5, 3:46 PM · Restricted Project, Restricted Project

Fri, Aug 30

dschuff accepted D67015: [lld][WebAssembly] Fix spurious signature mismatch warnings.
Fri, Aug 30, 12:37 PM · Restricted Project

Thu, Aug 29

dschuff added a comment to D66983: [WebAssembly] Add wasm-specific vector shuffle builtin and intrinsic.

Oh, interesting I didn't notice that those are implementations of the target-specific intrinsics. I wonder if they do that so they can implement the intrinsics on hardware that doesn't support the corresponding instruction? In a situation other than that I think I'd be surprised if I used a builtin for a particular instruction and got something else.

Thu, Aug 29, 5:55 PM · Restricted Project, Restricted Project
dschuff added a comment to D66983: [WebAssembly] Add wasm-specific vector shuffle builtin and intrinsic.

I think the expectation is that if you use an intrinsics header that has an intrinsic for each machine instruction, that each intrinsic call should result in exactly one machine instruction with the same arguments you passed to it. If the vector operation is created some other way (e.g. autovectorization or even __builtin_shufflevector) then I agree that there doesn't necessarily have to be that expectation.

Thu, Aug 29, 5:49 PM · Restricted Project, Restricted Project

Wed, Aug 28

dschuff added a comment to D66794: [WebAssembly] Add atomic.fence instruction.

great, LGTM!

Wed, Aug 28, 9:54 AM · Restricted Project

Tue, Aug 27

dschuff accepted D66794: [WebAssembly] Add atomic.fence instruction.
Tue, Aug 27, 8:56 AM · Restricted Project

Mon, Aug 26

dschuff accepted D66729: [WebAssembly] Fix SSA rebuilding in SjLj transformation.
Mon, Aug 26, 10:25 AM · Restricted Project
dschuff accepted D66728: [WebAssembly] Combine emscripten SjLj tests.
Mon, Aug 26, 9:54 AM · Restricted Project

Aug 22 2019

dschuff accepted D59890: [MC] Minor cleanup to MCFixup::Kind handling. NFC..

Nice.

Aug 22 2019, 2:48 PM · Restricted Project

Aug 20 2019

dschuff accepted D66455: [WebAssembly][MC] Simplify WasmObjectWriter::recordRelocation. NFC..
Aug 20 2019, 2:21 PM · Restricted Project
dschuff added a comment to D66455: [WebAssembly][MC] Simplify WasmObjectWriter::recordRelocation. NFC..

So it looks like this change is just that we now report an error where it asserted before?

Aug 20 2019, 7:50 AM · Restricted Project

Aug 19 2019

dschuff added inline comments to D66434: [WebAssembly][MC] Allow empty assembly functions.
Aug 19 2019, 12:11 PM · Restricted Project

Aug 15 2019

dschuff accepted D66255: [WebAssembly] Correctly handle va_arg of zero-sized structures.
Aug 15 2019, 12:24 PM · Restricted Project, Restricted Project

Aug 14 2019

dschuff added inline comments to D66255: [WebAssembly] Correctly handle va_arg of zero-sized structures.
Aug 14 2019, 2:26 PM · Restricted Project, Restricted Project

Aug 13 2019

dschuff accepted D66168: [WebAssembly] Make clang emit correct va_arg code for structs.

LGTM. Nice that we had a test which tested the wrong thing.

Aug 13 2019, 2:17 PM · Restricted Project, Restricted Project

Aug 12 2019

dschuff accepted D65922: [lld][WebAssembly] Allow linking of PIC code into static binaries.
Aug 12 2019, 3:39 PM · Restricted Project

Aug 8 2019

dschuff added inline comments to D65922: [lld][WebAssembly] Allow linking of PIC code into static binaries.
Aug 8 2019, 11:20 AM · Restricted Project

Aug 7 2019

dschuff accepted D65475: [WebAssembly] Fix __clang_call_termiante's argument for foreign exceptions.
Aug 7 2019, 1:03 PM · Restricted Project

Jul 18 2019

dschuff accepted D64955: Fix formatting of inline argument comments. NFC..
Jul 18 2019, 5:16 PM · Restricted Project, Restricted Project

Jul 16 2019

dschuff added a comment to D64537: [WebAssembly] Implement thread-local storage (local-exec model).

I had a reply that got eaten here, so I'm going to keep trolling you on your CL since we don't have a design doc for this.
The offset field of a data segment initializer can be a global.get on an imported global. (https://webassembly.github.io/spec/core/valid/instructions.html#constant-expressions). Since each thread is separately instantiated with separate JS, we could have a global import like __tls_base which has a different value in each thread. Then we wouldn't need to manually call the init code anywhere. Would there be other advantages or disadvantages for that?

Jul 16 2019, 5:10 PM · Restricted Project, Restricted Project

Jul 15 2019

dschuff added a comment to D64537: [WebAssembly] Implement thread-local storage (local-exec model).

Another high-level question (based just on reading the CL description): The TLS-size intrinsic is per-function, does that mean that the tls-init function is called for every function? are there just multiple TLS sections per object file?

Jul 15 2019, 3:24 PM · Restricted Project, Restricted Project
dschuff added a comment to D64537: [WebAssembly] Implement thread-local storage (local-exec model).

The offset field of a segment can be a constant expression which can be a global.get of an imported global. So we could have an imported global __tls_base which is different for each thread, and have an active segment with that as its segment offset?

Jul 15 2019, 3:21 PM · Restricted Project, Restricted Project
dschuff accepted D64770: [WebAssembly] Assembler: support special floats: infinity / nan.
Jul 15 2019, 2:34 PM · Restricted Project
dschuff accepted D64703: [WebAssembly] Rename except_ref type to exnref.
Jul 15 2019, 2:07 PM · Restricted Project

Jul 12 2019

dschuff added a comment to D52634: [WebAssembly] Add DBG_VALUE with local operands location in WebAssemblyExplicitLocals pass.

Let's work toward getting this landed!
@yurydelendik Your note mentioned that you reverted the breg version based on some kind of incompatibility, can you say more about that?

Jul 12 2019, 5:25 PM · Restricted Project, debug-info
dschuff added a comment to D64537: [WebAssembly] Implement thread-local storage (local-exec model).

Oh, btw, any reason these have to be passive segments? Why can't we just make them active segments and let the VM initialize them for us?

Jul 12 2019, 5:00 PM · Restricted Project, Restricted Project
dschuff added a comment to D64537: [WebAssembly] Implement thread-local storage (local-exec model).

If there's any chance this TLS ABI could be useful for WASI (I don't know if there's been any WASI work on threads yet, but it seems like there's no reason it couldn't be), then we should start a doc in tool-conventions for it. If not then we should get it behind the emscripten OS in LLVM. (and document it anyway; either in tool-conventions or somewhere in the emscripten site).

Jul 12 2019, 4:58 PM · Restricted Project, Restricted Project

Jul 9 2019

dschuff accepted D64322: [WebAssembly] Print error message for llvm.clear_cache intrinsic.

This is fine (assuming getClearCacheBuiltinName is only called when clear_cache is itself called in the source), and an improvement over just asserting. I'm curious to hear what the OP says about their use case, we can always discuss changing this in the future.

Jul 9 2019, 1:05 PM · Restricted Project
dschuff added a comment to D64439: [lld][WebAssembly] Fix data section name in PIC mode.

LGTM

Jul 9 2019, 1:00 PM · Restricted Project
dschuff added a comment to D64322: [WebAssembly] Print error message for llvm.clear_cache intrinsic.

Another view would be that we accept that this probably doesn't get used in code that would be useful in wasm, but maybe it's in a file that has other useful code, so this would basically be a convenience feature that allows users to have fewer ifdefs in their files (even with the assumption that they aren't going to be calling this code). Someone did, after all, actually run into this problem. Speaking of, maybe we should ask them what their use case is, why they even want to compile this code?

Jul 9 2019, 11:36 AM · Restricted Project
dschuff accepted D64367: [WebAssembly] Assembler: support negative float constants..
Jul 9 2019, 7:55 AM · Restricted Project

Jul 3 2019

dschuff committed rG51d3c4dfcd73: [WebAssembly] Update test failure explanations (authored by dschuff).
[WebAssembly] Update test failure explanations
Jul 3 2019, 5:26 PM
dschuff committed rL365100: [WebAssembly] Update test failure explanations.
[WebAssembly] Update test failure explanations
Jul 3 2019, 5:24 PM
dschuff committed rGec4be576554c: [WebAssembly] Enable IndirectBrExpandPass (authored by dschuff).
[WebAssembly] Enable IndirectBrExpandPass
Jul 3 2019, 4:56 PM
dschuff committed rL365096: [WebAssembly] Enable IndirectBrExpandPass.
[WebAssembly] Enable IndirectBrExpandPass
Jul 3 2019, 4:55 PM
dschuff closed D64161: [WebAssembly] Enable IndirectBrExpandPass.
Jul 3 2019, 4:55 PM · Restricted Project
dschuff created D64161: [WebAssembly] Enable IndirectBrExpandPass.
Jul 3 2019, 2:27 PM · Restricted Project

Jul 1 2019

dschuff accepted D64039: [WebAssembly] tablegen: distinguish float/int immediate operands..
Jul 1 2019, 2:58 PM · Restricted Project
dschuff added a comment to D64039: [WebAssembly] tablegen: distinguish float/int immediate operands..

Wow, that was simple.
Is there a "bad" asm parser test we can add now to test this?

Jul 1 2019, 2:46 PM · Restricted Project

Jun 28 2019

dschuff accepted D63836: [llvm-ar] Document response file support in --help.
Jun 28 2019, 9:02 AM · Restricted Project

Jun 27 2019

dschuff added inline comments to D63901: [WebAssembly] Added visibility and ident directives to WasmAsmParser..
Jun 27 2019, 4:29 PM · Restricted Project

Jun 20 2019

dschuff accepted D63615: [WebAssembly] Omit wrap on i64x2.{shl,shr*} ISel when possible.
Jun 20 2019, 12:44 PM · Restricted Project

Jun 18 2019

dschuff accepted D63529: [WebAssembly] Optimize ISel for SIMD Boolean reductions.
Jun 18 2019, 4:44 PM · Restricted Project

Jun 11 2019

dschuff added a comment to D63081: [WebAssembly] Cleanup toolchain test files. NFC..

LGTM

Jun 11 2019, 12:00 AM · Restricted Project, Restricted Project

Jun 6 2019

dschuff added inline comments to D62877: [WebAssembly] Implement tail calls and unify tablegen call classes.
Jun 6 2019, 10:52 PM · Restricted Project

Jun 4 2019

dschuff added inline comments to D62877: [WebAssembly] Implement tail calls and unify tablegen call classes.
Jun 4 2019, 10:48 PM · Restricted Project

May 29 2019

dschuff accepted D62542: [WebAssembly] Make Emscripten-specific behavior specific to the Emscripten target.
May 29 2019, 8:50 AM · Restricted Project
dschuff added a comment to D62542: [WebAssembly] Make Emscripten-specific behavior specific to the Emscripten target.

LGTM in general. Maybe IMPLICITLY_EXPORTED would be an even better name?
Anyway, I'm hoping we can make that export behavior nicer soon; I find the attribute(used) -> export behavior a bit odd too. Once we drop fastcomp it will be easier to redefine EMSCRIPTEN_KEEPALIVE and other things.

May 29 2019, 8:50 AM · Restricted Project

May 28 2019

dschuff added a comment to D62564: [WebAssembly] Add signatures for RINT builtins.

LGTM

May 28 2019, 9:43 PM · Restricted Project
dschuff accepted D50277: [WebAssembly] Support for atomic fences.

LGTM modulo the indentation thing.

May 28 2019, 2:04 PM · Restricted Project

May 24 2019

dschuff added a comment to D50277: [WebAssembly] Support for atomic fences.

Yeah I agree with your assessment that this doesn't give us a future-proof ABI; that's why I want to revisit it later. Mostly this is to unblock removing fastcomp.

May 24 2019, 5:49 PM · Restricted Project
dschuff added a comment to D50277: [WebAssembly] Support for atomic fences.

Given the discussion on the github issues, we have scheduled a discussion at the in-person CG meeting that should resolve the outstanding memory model issues, possibly with a change to the spec.

May 24 2019, 4:45 PM · Restricted Project
dschuff accepted D62153: [WebAssembly] Relax signature checking for undefined functions that are not called directly.

Otherwise LGTM

May 24 2019, 11:22 AM · Restricted Project

May 21 2019

dschuff accepted D62207: [WebAssembly] Add the signature for the new llround builtin function.
May 21 2019, 2:12 PM · Restricted Project

May 16 2019

dschuff added a comment to D62040: [docs] Add new document on building distributions.

This is great! Might it be worth mentioning LLVM_INSTALL_TOOLCHAIN_ONLY somewhere?

May 16 2019, 3:52 PM · Restricted Project
dschuff accepted D61971: [WebAssembly] Move code and data sectiion generation to finalizeContent. NFC..
May 16 2019, 1:14 PM · Restricted Project
dschuff accepted D61991: [WebAssembly] Don't generate empty type section..
May 16 2019, 1:12 PM · Restricted Project

Apr 30 2019

dschuff accepted D61351: [WebAssembly] Update expectations for gcc torture tests.
Apr 30 2019, 4:04 PM · Restricted Project
dschuff accepted D61287: [WebAssembly] Support f16 libcalls.
Apr 30 2019, 10:39 AM · Restricted Project

Apr 24 2019

dschuff added a comment to D60986: [WebAssembly] Bail out of fastisel earlier when computing PIC addresses.

LGTM

Apr 24 2019, 11:22 AM · Restricted Project
dschuff added inline comments to D60966: [WebAssembly] Emit br_table for most switch instructions.
Apr 24 2019, 10:33 AM · Restricted Project

Apr 12 2019

dschuff accepted D60623: [WebAssembly] Add DataCount section to object files.

I assume the linker doesn't need to do anything with this, it can just regenerate it after linking?

Apr 12 2019, 1:58 PM · Restricted Project

Apr 11 2019

dschuff accepted D60594: [WebAssembly] Add mutable-globals to bleeding-edge CPU.
Apr 11 2019, 6:03 PM · Restricted Project

Apr 4 2019

dschuff accepted D59907: [WebAssembly] Add new explicit relocation types for PIC relocations.

I guess the lld code here is an even better answer to my question on the tool-conventions review: the linker behavior is exactly the same.

Apr 4 2019, 9:42 AM · Restricted Project

Apr 2 2019

dschuff accepted D60014: [WebAssembly] Remove unneeded target operand flags.

I think these are leftovers from when we were using ELF.

Apr 2 2019, 4:50 PM · Restricted Project

Mar 29 2019

dschuff accepted D60004: [WebAssembly] Handle END_LOOP in unreachable BB in CFGStackify.
Mar 29 2019, 12:30 PM · Restricted Project

Mar 28 2019

dschuff committed rG0c9ea1053058: Revert "[WebAssembly] Improve invalid relocation error message" (authored by dschuff).
Revert "[WebAssembly] Improve invalid relocation error message"
Mar 28 2019, 5:04 PM
dschuff added a reverting change for rG0805ec5f7b5c: [WebAssembly] Improve invalid relocation error message: rG0c9ea1053058: Revert "[WebAssembly] Improve invalid relocation error message".
Mar 28 2019, 5:04 PM
dschuff committed rGac727e86473b: Revert "[WebAssembly] Improve invalid relocation error message" (authored by dschuff).
Revert "[WebAssembly] Improve invalid relocation error message"
Mar 28 2019, 5:04 PM
dschuff added a reverting change for rG0805ec5f7b5c: [WebAssembly] Improve invalid relocation error message: rGac727e86473b: Revert "[WebAssembly] Improve invalid relocation error message".
Mar 28 2019, 5:04 PM
dschuff added a reverting change for rGa9958fc30d0c: [WebAssembly] Fix typo from rL357143: rGac727e86473b: Revert "[WebAssembly] Improve invalid relocation error message".
Mar 28 2019, 5:04 PM
dschuff committed rLLD357225: Revert "[WebAssembly] Improve invalid relocation error message".
Revert "[WebAssembly] Improve invalid relocation error message"
Mar 28 2019, 5:03 PM
dschuff committed rLLD357224: Revert "[WebAssembly] Improve invalid relocation error message".
Revert "[WebAssembly] Improve invalid relocation error message"
Mar 28 2019, 5:03 PM
dschuff committed rL357225: Revert "[WebAssembly] Improve invalid relocation error message".
Revert "[WebAssembly] Improve invalid relocation error message"
Mar 28 2019, 5:03 PM
dschuff committed rL357224: Revert "[WebAssembly] Improve invalid relocation error message".
Revert "[WebAssembly] Improve invalid relocation error message"
Mar 28 2019, 5:03 PM

Mar 27 2019

dschuff accepted D59908: [WebAssembly] Rename wasm fixup kinds.
Mar 27 2019, 4:24 PM · Restricted Project
dschuff added a comment to D59743: [WebAssembly] Don't use default GetLinkerPath.

Reverted in rG039be787914610c28cba45c4557454e0a96939ab. Caused a strange error with the waterfall sysroot's build of libcxx: https://logs.chromium.org/logs/wasm/buildbucket/cr-buildbucket.appspot.com/8917800786005174656/+/steps/libcxx/0/stdout

Mar 27 2019, 3:23 PM · Restricted Project
dschuff committed rG039be7879146: Revert "[WebAssembly] Don't use default GetLinkerPath" (authored by dschuff).
Revert "[WebAssembly] Don't use default GetLinkerPath"
Mar 27 2019, 3:23 PM
dschuff added a reverting change for rG4dcf3acce6d7: [WebAssembly] Don't use default GetLinkerPath: rG039be7879146: Revert "[WebAssembly] Don't use default GetLinkerPath".
Mar 27 2019, 3:23 PM
dschuff committed rC357127: Revert "[WebAssembly] Don't use default GetLinkerPath".
Revert "[WebAssembly] Don't use default GetLinkerPath"
Mar 27 2019, 3:22 PM
dschuff committed rL357127: Revert "[WebAssembly] Don't use default GetLinkerPath".
Revert "[WebAssembly] Don't use default GetLinkerPath"
Mar 27 2019, 3:22 PM

Mar 26 2019

dschuff accepted D59855: [WebAssembly] Add some whitespace for clarity.

Macro shipit:

Mar 26 2019, 5:37 PM · Restricted Project
dschuff accepted D48345: [WebAssembly] Fix unwind destination mismatches in CFG stackify.
Mar 26 2019, 12:38 PM · Restricted Project
dschuff accepted D59740: [WebAssembly] Don't analyze branches after CFGStackify.
Mar 26 2019, 10:06 AM · Restricted Project

Mar 25 2019

dschuff added inline comments to D59740: [WebAssembly] Don't analyze branches after CFGStackify.
Mar 25 2019, 5:22 PM · Restricted Project
dschuff accepted D54647: [WebAssembly] Initial implementation of PIC code generation.

still LGTM. In a followup CL it should be straightforward to add back fast-isel and you might be able to re-use the same checks in load-store-pic.ll. (but you wouldn't need to add fast-isel+PIC to address-offsets.ll because that's testing an optimization that fast-isel doesn't do.)

Mar 25 2019, 5:14 PM · Restricted Project
dschuff accepted D59652: [WebAssembly] Run ExplicitLocals pass after CFGStackify.
Mar 25 2019, 3:37 PM · Restricted Project
dschuff added inline comments to D59740: [WebAssembly] Don't analyze branches after CFGStackify.
Mar 25 2019, 3:36 PM · Restricted Project
dschuff added inline comments to D59740: [WebAssembly] Don't analyze branches after CFGStackify.
Mar 25 2019, 3:30 PM · Restricted Project
dschuff accepted D59747: [WebAssembly] Add CFGStacikfied field to WebAssemblyFunctionInfo.
Mar 25 2019, 1:50 PM · Restricted Project
dschuff accepted D59737: [WebAssembly] Support WebAssemblyFunctionInfo serialization.
Mar 25 2019, 1:49 PM · Restricted Project
dschuff accepted D59751: [WebAssembly] Fix a bug when mixing TRY/LOOP markers.
Mar 25 2019, 1:46 PM · Restricted Project
dschuff accepted D59739: [WebAssembly] Fix bugs in BLOCK/TRY placement.

otherwise LGTM

Mar 25 2019, 1:41 PM · Restricted Project
dschuff accepted D59743: [WebAssembly] Don't use default GetLinkerPath.
Mar 25 2019, 10:13 AM · Restricted Project

Mar 19 2019

dschuff added inline comments to D48345: [WebAssembly] Fix unwind destination mismatches in CFG stackify.
Mar 19 2019, 3:22 PM · Restricted Project

Mar 18 2019

dschuff accepted D59519: [WebAssembly] Lower SIMD nnan setcc nodes.

to make the change even clearer, you could just say in the commit message that it just adds the missing non-equality opcodes.

Mar 18 2019, 5:36 PM · Restricted Project