whitequark (whitequark)
User

Projects

User does not belong to any projects.

User Details

User Since
Jan 21 2013, 11:58 AM (230 w, 4 d)

Recent Activity

Today

whitequark committed rL306142: [X86] Fix SP adjustment in stack probes emitted on 32-bit Windows..
[X86] Fix SP adjustment in stack probes emitted on 32-bit Windows.
Fri, Jun 23, 11:59 AM

Yesterday

whitequark committed rL306069: Define behavior of "stack-probe-size" attribute when inlining..
Define behavior of "stack-probe-size" attribute when inlining.
Thu, Jun 22, 4:23 PM
whitequark closed D34528: Define behavior of "stack-probe-size" attribute when inlining. by committing rL306069: Define behavior of "stack-probe-size" attribute when inlining..
Thu, Jun 22, 4:23 PM
whitequark updated the diff for D34528: Define behavior of "stack-probe-size" attribute when inlining..

Addressed review comments

Thu, Jun 22, 2:24 PM
whitequark created D34528: Define behavior of "stack-probe-size" attribute when inlining..
Thu, Jun 22, 1:19 PM
whitequark committed rL306010: [X86] Add support for "probe-stack" attribute.
[X86] Add support for "probe-stack" attribute
Thu, Jun 22, 8:43 AM
whitequark closed D34387: [PATCH 2/2] Implement "probe-stack" on x86 by committing rL306010: [X86] Add support for "probe-stack" attribute.
Thu, Jun 22, 8:43 AM

Wed, Jun 21

whitequark added a comment to D34387: [PATCH 2/2] Implement "probe-stack" on x86.

LGTM, but I'd still like to hear from @majnemer

Wed, Jun 21, 2:23 PM
whitequark added inline comments to D34387: [PATCH 2/2] Implement "probe-stack" on x86.
Wed, Jun 21, 12:12 PM
whitequark committed rL305939: Add a "probe-stack" attribute.
Add a "probe-stack" attribute
Wed, Jun 21, 11:47 AM
whitequark closed D34386: [PATCH 1/2] Add a "probe-stack" attribute (revised) by committing rL305939: Add a "probe-stack" attribute.
Wed, Jun 21, 11:47 AM

Tue, Jun 20

whitequark added a comment to D34387: [PATCH 2/2] Implement "probe-stack" on x86.

@pcwalton But I agree that it's better to change both sides of the __probestack ABI to eliminate the argument and the spill (on x86_64), of course.

Tue, Jun 20, 12:32 PM
whitequark added a comment to D34387: [PATCH 2/2] Implement "probe-stack" on x86.

@pcwalton No, both the spill and the "magic" number are necessary. See https://reviews.llvm.org/D9858. ebx is the size of the frame, and 0x1000 is the probe interval to be performed (in other words, page size).

Tue, Jun 20, 12:30 PM
whitequark added a comment to D34386: [PATCH 1/2] Add a "probe-stack" attribute (revised).

It looks like you inadvertently included an entire copy of D34387 here.

Tue, Jun 20, 1:20 AM

Mon, Jun 5

whitequark added inline comments to D32368: LLVM C DIBuilder Creation APIs.
Mon, Jun 5, 11:21 AM
whitequark added inline comments to D32368: LLVM C DIBuilder Creation APIs.
Mon, Jun 5, 10:59 AM
whitequark committed rL304709: [LLVM-C] [OCaml] Expose Type::subtypes..
[LLVM-C] [OCaml] Expose Type::subtypes.
Mon, Jun 5, 4:50 AM
whitequark closed D33677: subtypes for C and OCaml API by committing rL304709: [LLVM-C] [OCaml] Expose Type::subtypes..
Mon, Jun 5, 4:50 AM

Sun, Jun 4

whitequark added inline comments to D32368: LLVM C DIBuilder Creation APIs.
Sun, Jun 4, 2:26 PM

Fri, Jun 2

whitequark added inline comments to D32368: LLVM C DIBuilder Creation APIs.
Fri, Jun 2, 11:39 PM

Tue, May 30

whitequark accepted D33677: subtypes for C and OCaml API.
Tue, May 30, 2:56 PM
whitequark added inline comments to D33677: subtypes for C and OCaml API.
Tue, May 30, 2:32 PM
whitequark added a comment to D33677: subtypes for C and OCaml API.

Sure, unless you want to get all contained types as an array.

Tue, May 30, 1:40 PM
whitequark added a comment to D33677: subtypes for C and OCaml API.

I don't think anyone ever had a goal of covering the entire C++ API, the binding is produced demand-side.

Tue, May 30, 1:01 PM
whitequark added a comment to D33677: subtypes for C and OCaml API.

@TyanNN What's wrong with using element_type then?

Tue, May 30, 12:22 PM
whitequark added a comment to D33677: subtypes for C and OCaml API.

@deadalnix The use case is the same. The current API can assert, the one I suggest can not.

Tue, May 30, 11:52 AM
whitequark requested changes to D33677: subtypes for C and OCaml API.

On second thought I would prefer the OCaml interface to have a single function returning an array, since this is safer and easier to use.

Tue, May 30, 11:09 AM
whitequark accepted D33677: subtypes for C and OCaml API.
Tue, May 30, 7:47 AM

May 19 2017

whitequark requested changes to D32368: LLVM C DIBuilder Creation APIs.
May 19 2017, 12:39 PM

May 11 2017

whitequark added a comment to D18738: Add new !unconditionally_dereferenceable load instruction metadata.

@hfinkel Oh, my bad--I now remember that this came up long ago...

May 11 2017, 1:23 PM
whitequark added a comment to D18738: Add new !unconditionally_dereferenceable load instruction metadata.

I'd be okay (even happy! :) ) if you add a @llvm.safe.load.<ty> intrinsic that never has UB, and returns undef if the address passed to it is not dereferenceable. That intrinsic could then be marked speculatable. If needed, we could even implement the intrinsic by trying to read from the address passed in, and by catching the SIGSEGV or SIGBUS, if any.

May 11 2017, 11:37 AM
D18738: Add new !unconditionally_dereferenceable load instruction metadata now requires changes to proceed.

@sanjoy Since D20116 is in, is there any reason to avoid having a !speculatable on load instructions? It can be emulated anyway by defining a class of @load.x functions marked speculatable and their return value dereferenceable, so there is no loss of soundness.

May 11 2017, 6:50 AM

Apr 21 2017

whitequark added inline comments to D32368: LLVM C DIBuilder Creation APIs.
Apr 21 2017, 12:50 PM

Apr 19 2017

whitequark accepted D32122: Introduce LLVMDIBuilderRef.
Apr 19 2017, 2:13 PM

Apr 17 2017

whitequark added a comment to D32122: Introduce LLVMDIBuilderRef.

The real question is established bindings like the OCaml and python bindings -- would they be willing to use this API with breaking changes?

Apr 17 2017, 12:29 PM

Jan 25 2017

whitequark committed rL293041: Mark @llvm.powi.* as safe to speculatively execute..
Mark @llvm.powi.* as safe to speculatively execute.
Jan 25 2017, 1:43 AM

Jan 4 2017

whitequark accepted D28294: [cmake] Canonicalize CMake booleans to 0/1 for Python interop.

Seems good to me!

Jan 4 2017, 12:19 PM

Nov 12 2016

whitequark accepted D26580: [OCaml] Clear cross-target test deps when building out-of-tree.
Nov 12 2016, 6:46 AM

Nov 11 2016

whitequark committed rL286705: [OCaml] Adapt to the new attribute C API..
[OCaml] Adapt to the new attribute C API.
Nov 11 2016, 7:48 PM
whitequark committed rL286704: [C API] Fix several null pointer dereferences..
[C API] Fix several null pointer dereferences.
Nov 11 2016, 7:48 PM
whitequark added a comment to D18738: Add new !unconditionally_dereferenceable load instruction metadata.

@sanjoy OK, I understand now. In a nutshell, our disagreement was in whether dead code in IR can affect semantics of live code. This doesn't strike me as particularly bad (even after looking at your examples--clearly they shouldn't use !unconditionally_dereferenceable, but that doesn't mean it's not useful elsewhere), but you clearly have more experience here, so I won't argue that my approach is viable for upstream.

Nov 11 2016, 6:55 AM

Nov 10 2016

whitequark added a comment to D18738: Add new !unconditionally_dereferenceable load instruction metadata.

@sanjoy Your example is being transformed as expected, from my POV. The idea is that an unconditionally dereferenceable load cannot be moved across a store that may-alias the pointer, and this lets one initialize it safely. Other than immediately after allocation, a pointer which is ever loaded like that must always be dereferenceable.

Nov 10 2016, 12:46 PM
whitequark added a comment to D26501: [LICM] Retain load instruction invariant metadata when hoisting.

@hfinkel OK, I see. I wonder if the desired optimizations here as well as in D18738 could be more easily handled by loop peeling.

What do you mean? I don't see how loop peeling generally solves this hosting-out-of-nested-loops problem.

Nov 10 2016, 10:42 AM
whitequark added a comment to D26501: [LICM] Retain load instruction invariant metadata when hoisting.

@hfinkel OK, I see. I wonder if the desired optimizations here as well as in D18738 could be more easily handled by loop peeling.

Nov 10 2016, 10:33 AM
whitequark abandoned D2176: [llvm-c] Improve IR introspection.

Stale and no time to update in sight.

Nov 10 2016, 7:32 AM
whitequark updated the diff for D26501: [LICM] Retain load instruction invariant metadata when hoisting.

Actually updated the diff this time.

Nov 10 2016, 7:31 AM
whitequark updated the diff for D26501: [LICM] Retain load instruction invariant metadata when hoisting.

Loads of pointers are not hoisted for some reason, so keeping the pointer-related metadata makes no sense for now. Amended patch to be less aggressive and only keep !invariant.load.

Nov 10 2016, 7:30 AM
whitequark requested review of D18738: Add new !unconditionally_dereferenceable load instruction metadata.

The source level rule is as follows: I have a memory-safe language with region-based memory management. Once an object is constructed, pointers to it are guaranteed by the frontend to live no longer than the object. Thus, most* pointers constructed, even in dead code, can be dereferenced at any time when it is possible at all to construct it.

Nov 10 2016, 7:23 AM
whitequark retitled D26501: [LICM] Retain load instruction invariant metadata when hoisting from to [LICM] Retain load instruction metadata when hoisting.
Nov 10 2016, 6:57 AM

Oct 4 2016

whitequark committed rL283203: [SelectionDAG] Fix calling convention in expansion of ?MULO..
[SelectionDAG] Fix calling convention in expansion of ?MULO.
Oct 4 2016, 2:16 AM
whitequark closed D25223: [SelectionDAG] Fix calling convention in expansion of ?MULO. by committing rL283203: [SelectionDAG] Fix calling convention in expansion of ?MULO..
Oct 4 2016, 2:16 AM

Oct 3 2016

whitequark updated the diff for D25223: [SelectionDAG] Fix calling convention in expansion of ?MULO..

Added explanatory comment

Oct 3 2016, 11:54 PM
whitequark added a comment to D25223: [SelectionDAG] Fix calling convention in expansion of ?MULO..

Maybe ppc32 big endian for the testcase?

Oct 3 2016, 9:24 PM
whitequark updated D25223: [SelectionDAG] Fix calling convention in expansion of ?MULO..
Oct 3 2016, 9:08 PM
whitequark added a comment to D25223: [SelectionDAG] Fix calling convention in expansion of ?MULO..

It is quite regretful that this change comes without tests, but I wasn't able to trick any of the existing in-tree bi-endian backends into generating a __muldi3 sequence that I need to match against. Even worse, just unconditionally swapping the registers doesn't break any of the tests, implying that this branch wasn't tested in the first place (and also that there's nothing I can easily modify).

Oct 3 2016, 9:02 PM
whitequark retitled D25223: [SelectionDAG] Fix calling convention in expansion of ?MULO. from to [SelectionDAG] Fix calling convention in expansion of ?MULO..
Oct 3 2016, 8:59 PM
whitequark added a comment to D22736: Make LLVMInitializeAll* API have their symbols.

@nagisa ping?

Oct 3 2016, 8:50 PM

Sep 30 2016

whitequark accepted D25128: [OCaml] Install .mli (interface) files.

LGTM

Sep 30 2016, 2:08 PM
whitequark accepted D24354: cmake: Install the OCaml libraries into a more correct path.

LGTM

Sep 30 2016, 10:41 AM

Sep 20 2016

whitequark added inline comments to D24354: cmake: Install the OCaml libraries into a more correct path.
Sep 20 2016, 12:15 PM
whitequark added a comment to D24354: cmake: Install the OCaml libraries into a more correct path.

@jpdeplaix can you please test the updated patch also?

Sep 20 2016, 6:34 AM

Sep 9 2016

whitequark added a comment to D24354: cmake: Install the OCaml libraries into a more correct path.

@jpdeplaix Can you please also test the changes? Once I get ACK from you I will commit.

Sep 9 2016, 3:35 AM
whitequark added inline comments to D24354: cmake: Install the OCaml libraries into a more correct path.
Sep 9 2016, 3:19 AM

Sep 8 2016

whitequark added a comment to D24355: cmake: Make OCaml library install path configurable.

I don't see any point in having them separately in git either, it is just confusing since you are making logically one change to one component...

Sep 8 2016, 11:06 AM
whitequark added a comment to D24355: cmake: Make OCaml library install path configurable.

Please just fold these three patches into one.

Sep 8 2016, 10:43 AM
whitequark added a comment to D24354: cmake: Install the OCaml libraries into a more correct path.

But doesn't OCAML_STDLIB_PATH include /usr? So you would be installing to /usr/local/usr/lib/ocaml with the default config, unless I'm missing something.

Sep 8 2016, 10:42 AM

Sep 5 2016

whitequark committed rL280667: CODE_OWNERS: bring my entry up to date.
CODE_OWNERS: bring my entry up to date
Sep 5 2016, 10:51 AM

Sep 4 2016

whitequark committed rL280642: [CMake] [OCaml] Allow building OCaml bindings out of tree..
[CMake] [OCaml] Allow building OCaml bindings out of tree.
Sep 4 2016, 6:50 PM

Aug 30 2016

whitequark added a comment to D22736: Make LLVMInitializeAll* API have their symbols.

@nagisa, please test your changes on Windows and OS X. (For reference the commit that introduced it can be seen at rL192690 and the revert at rL192697.)

Aug 30 2016, 9:52 AM
whitequark added a comment to D9653: [PATCH 1/2] Add a "probe-stack" attribute.

@majnemer ping? I am also interested in this.

Aug 30 2016, 5:14 AM
whitequark committed rL280071: docs: mention that clobbering output regs in inline asm is illegal..
docs: mention that clobbering output regs in inline asm is illegal.
Aug 30 2016, 3:57 AM

Aug 23 2016

whitequark closed D23763: cmake: Add LLVM_ENABLE_OCAMLDOC to control building OCaml bindings doc.

rL279544

Aug 23 2016, 11:15 AM
whitequark committed rL279544: [CMake] [OCaml] Add -DLLVM_ENABLE_OCAMLDOC switch.
[CMake] [OCaml] Add -DLLVM_ENABLE_OCAMLDOC switch
Aug 23 2016, 11:15 AM

Aug 22 2016

whitequark accepted D23763: cmake: Add LLVM_ENABLE_OCAMLDOC to control building OCaml bindings doc.

LGTM

Aug 22 2016, 7:27 AM

Jul 24 2016

whitequark added a reviewer for D22736: Make LLVMInitializeAll* API have their symbols: echristo.

@echristo Assuming this works as one would expect, this is a massive improvement. However, I'm not completely certain of all subtle build system behavior. Do you see any potential downsides?

Jul 24 2016, 8:48 AM
whitequark added a comment to D22734: Make LLVMInitializeAll* API have their symbols.

@nagisa, yes, I think that will work.

Jul 24 2016, 2:41 AM
whitequark requested changes to D22734: Make LLVMInitializeAll* API have their symbols.

@nagisa, they are deliberately inline and deliberately unavailable for FFI use. After your change, every single executable statically linking to Target will link every individual backend, which makes them at least 200-500MB larger and increases link times by 10-60s (ballpark numbers).

Jul 24 2016, 2:10 AM

Jul 20 2016

whitequark added a comment to D21265: Expose AttributeSetNode, use it to provide aggregate getter for attribute in the C API..

@deadalnix, So, no aggregate getters at all? That's unacceptable.

Jul 20 2016, 10:06 PM

Jun 21 2016

whitequark committed rL273370: [OCaml] Add functions for accessing metadata nodes..
[OCaml] Add functions for accessing metadata nodes.
Jun 21 2016, 8:37 PM
whitequark closed D19309: OCaml bindings: Add functions for accessing metadata nodes by committing rL273370: [OCaml] Add functions for accessing metadata nodes..
Jun 21 2016, 8:37 PM
whitequark accepted D19309: OCaml bindings: Add functions for accessing metadata nodes.

LGTM

Jun 21 2016, 2:45 AM

Jun 15 2016

whitequark accepted D21365: Add support for string attributes in the C API..

LGTM

Jun 15 2016, 7:45 AM

Jun 14 2016

whitequark accepted D21266: Add support for callsite in the new C API for attributes.

LGTM

Jun 14 2016, 7:51 PM

Jun 13 2016

whitequark added a comment to D21316: Remove the ScalarReplAggregates pass.

This is great!

Jun 13 2016, 5:17 PM

Jun 11 2016

whitequark accepted D19181: Map Attribute in the C API..
Jun 11 2016, 10:32 PM
whitequark accepted D21265: Expose AttributeSetNode, use it to provide aggregate getter for attribute in the C API..

Aggregate getters LGTM

Jun 11 2016, 8:51 PM
whitequark added a comment to D19181: Map Attribute in the C API..

As per IRC discussion, some renaming

Jun 11 2016, 6:13 PM
whitequark added inline comments to D19181: Map Attribute in the C API..
Jun 11 2016, 5:40 PM
whitequark added inline comments to D19181: Map Attribute in the C API..
Jun 11 2016, 5:26 PM
whitequark requested changes to D19181: Map Attribute in the C API..
Jun 11 2016, 5:13 PM
whitequark added inline comments to D19181: Map Attribute in the C API..
Jun 11 2016, 5:13 PM

May 23 2016

whitequark accepted D20417: Extract renaming from D19181.

LGTM.

May 23 2016, 5:43 AM

May 10 2016

whitequark accepted D19828: [OCaml] Update core test and re-enable testing.

LGTM

May 10 2016, 4:16 AM

May 3 2016

whitequark added inline comments to D19828: [OCaml] Update core test and re-enable testing.
May 3 2016, 2:08 AM

Apr 27 2016

whitequark added a comment to D19181: Map Attribute in the C API..

Why do you say adding a single attribute is the most common use-case? I'd expect the most common use to be to be creating a function definition/declaration/call instruction from scratch, with a given set of specified function/parameter/return-value attributes. Which is ideally suited for constructing an attribute set, and then calling a setter to place it onto the instruction. Why do you think RMW operations would be primary?

Apr 27 2016, 8:30 PM
whitequark added a comment to D19181: Map Attribute in the C API..

@jyknight I strongly dislike exposing AttributeSet. What is the proposed usecase? FFI calls are expensive and using AttributeSet requires at least three operations (RMW) instead of one (Add) for the most common case (adding a single attribute). Further, AttributeSet is not easily interrogated; to get the full list of attributes, I propose (in the future) to add a function that returns an array of LLVMAttributeRef, which is again much nicer to bindings.

Apr 27 2016, 5:36 AM

Apr 26 2016

whitequark added a comment to D19181: Map Attribute in the C API..

I have no more objections.

Apr 26 2016, 5:51 PM
whitequark added inline comments to D19181: Map Attribute in the C API..
Apr 26 2016, 5:48 PM
whitequark added a comment to D19181: Map Attribute in the C API..

One thing I would like to have right away is a way to get the kind of an attribute. Looks good otherwise.

Apr 26 2016, 5:36 PM
whitequark requested changes to D19309: OCaml bindings: Add functions for accessing metadata nodes.
Apr 26 2016, 11:38 AM