|
Revision tags: llvmorg-5.0.1-rc2 |
|
| #
2803bfaf |
| 28-Nov-2017 |
Dan Gohman <[email protected]> |
[WebAssembly] Support bitcasted function addresses with varargs.
Generalize FixFunctionBitcasts to handle varargs functions. This in particular fixes the case where clang bitcasts away a varargs whe
[WebAssembly] Support bitcasted function addresses with varargs.
Generalize FixFunctionBitcasts to handle varargs functions. This in particular fixes the case where clang bitcasts away a varargs when calling a K&R-style function.
This avoids interacting with tricky ABI details because it operates at the LLVM IR level before varargs ABI details are exposed.
This fixes PR35385.
llvm-svn: 319186
show more ...
|
|
Revision tags: llvmorg-5.0.1-rc1 |
|
| #
37af00e7 |
| 10-Oct-2017 |
Jacob Gravelle <[email protected]> |
[WebAssembly] Narrow the scope of WebAssemblyFixFunctionBitcasts
Summary: The pass to fix function bitcasts generates thunks for functions that are called directly with a mismatching signature. It w
[WebAssembly] Narrow the scope of WebAssemblyFixFunctionBitcasts
Summary: The pass to fix function bitcasts generates thunks for functions that are called directly with a mismatching signature. It was also generating thunks in cases where the function was address-taken, causing aliasing problems in otherwise valid cases. This patch tightens the restrictions for when the pass runs.
Reviewers: sunfish, dschuff
Subscribers: jfb, sbc100, llvm-commits, aheejin
Differential Revision: https://reviews.llvm.org/D38640
llvm-svn: 315326
show more ...
|
|
Revision tags: llvmorg-5.0.0, llvmorg-5.0.0-rc5, llvmorg-5.0.0-rc4, llvmorg-5.0.0-rc3, llvmorg-5.0.0-rc2, llvmorg-5.0.0-rc1, llvmorg-4.0.1, llvmorg-4.0.1-rc3, llvmorg-4.0.1-rc2, llvmorg-4.0.1-rc1, llvmorg-4.0.0, llvmorg-4.0.0-rc4, llvmorg-4.0.0-rc3 |
|
| #
d37dc2f7 |
| 27-Feb-2017 |
Dan Gohman <[email protected]> |
[WebAssembly] Add some comments and tidy up whitespace.
llvm-svn: 296402
|
|
Revision tags: llvmorg-4.0.0-rc2 |
|
| #
a99b717f |
| 20-Jan-2017 |
Dan Gohman <[email protected]> |
[WebAssembly] Don't create bitcast-wrappers for varargs.
WebAssembly varargs functions use a significantly different ABI than non-varargs functions, and the current code in WebAssemblyFixFunctionBit
[WebAssembly] Don't create bitcast-wrappers for varargs.
WebAssembly varargs functions use a significantly different ABI than non-varargs functions, and the current code in WebAssemblyFixFunctionBitcasts doesn't handle that difference. For now, just avoid creating wrapper functions in the presence of varargs.
llvm-svn: 292645
show more ...
|
|
Revision tags: llvmorg-4.0.0-rc1 |
|
| #
7acb42a4 |
| 10-Jan-2017 |
Derek Schuff <[email protected]> |
[WebAssembly] Only RAUW a constant once in FixFunctionBitcasts
When we collect 2 uses of a function in FindUses and then RAUW when we visit the first, we end up visiting the wrapper (because the sec
[WebAssembly] Only RAUW a constant once in FixFunctionBitcasts
When we collect 2 uses of a function in FindUses and then RAUW when we visit the first, we end up visiting the wrapper (because the second was RAUW'd). We still want to use RAUW instead of just Use->set() because it has special handling for Constants, so this patch just ensures that only one use of each constant is added to the work list.
Differential Revision: https://reviews.llvm.org/D28504
llvm-svn: 291603
show more ...
|
| #
0e2ceb81 |
| 07-Jan-2017 |
Dan Gohman <[email protected]> |
[WebAssembly] Don't abort on code with UB.
Gracefully leave code that performs function-pointer bitcasts implying non-trivial pointer conversions alone, rather than aborting, since it's just undefin
[WebAssembly] Don't abort on code with UB.
Gracefully leave code that performs function-pointer bitcasts implying non-trivial pointer conversions alone, rather than aborting, since it's just undefined behavior.
llvm-svn: 291326
show more ...
|
| #
d5eda355 |
| 07-Jan-2017 |
Dan Gohman <[email protected]> |
[WebAssembly] Move a SmallVector to a more specific scope. NFC.
llvm-svn: 291324
|
| #
1b637458 |
| 07-Jan-2017 |
Dan Gohman <[email protected]> |
[WebAssembly] Add a pass to create wrappers for function bitcasts.
WebAssembly requires caller and callee signatures to match exactly. In LLVM, there are a variety of circumstances where signatures
[WebAssembly] Add a pass to create wrappers for function bitcasts.
WebAssembly requires caller and callee signatures to match exactly. In LLVM, there are a variety of circumstances where signatures may be mismatched in practice, and one can bitcast a function address to another type to call it as that type. This patch adds a pass which replaces bitcasted function addresses with wrappers to replace the bitcasts.
This doesn't catch everything, but it does match many common cases.
llvm-svn: 291315
show more ...
|