<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/src/rustllvm/PassWrapper.cpp, branch 1.19.0</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=1.19.0</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=1.19.0'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2017-05-01T17:23:09+00:00</updated>
<entry>
<title>Auto merge of #41560 - alevy:rwpi-ropi, r=eddyb</title>
<updated>2017-05-01T17:23:09+00:00</updated>
<author>
<name>bors</name>
<email>bors@rust-lang.org</email>
</author>
<published>2017-05-01T17:23:09+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=4cb396c68088f38e517ac8890030d17a969e57ba'/>
<id>urn:sha1:4cb396c68088f38e517ac8890030d17a969e57ba</id>
<content type='text'>
Add RWPI/ROPI relocation model support

This PR adds support for using LLVM 4's ROPI and RWPI relocation models for ARM.

ROPI (Read-Only Position Independence) and RWPI (Read-Write Position Independence) are two new relocation models in LLVM for the ARM backend ([LLVM changset](https://reviews.llvm.org/rL278015)). The motivation is that these are the specific strategies we use in userspace [Tock](https://www.tockos.org) apps, so supporting this is an important step (perhaps the final step, but can't confirm yet) in enabling userspace Rust processes.

## Explanation

ROPI makes all code and immutable accesses PC relative, but not assumed to be overriden at runtime (so for example, jumps are always relative).

RWPI uses a base register (`r9`) that stores the addresses of the GOT in memory so the runtime (e.g. a kernel) only adjusts r9 tell running code where the GOT is.

## Complications adding support in Rust

While this landed in LLVM master back in August, the header files in `llvm-c` have not been updated yet to reflect it. Rust replicates that header file's version of the `LLVMRelocMode` enum as the Rust enum `llvm::RelocMode` and uses an implicit cast in the ffi to translate from Rust's notion of the relocation model to the LLVM library's notion.

My workaround for this currently is to replace the `LLVMRelocMode` argument to `LLVMTargetMachineRef` with an int and using the hardcoded int representation of the `RelocMode` enum. This is A Bad Idea(tm), but I think very nearly the right thing.

Would a better alternative be to patch rust-llvm to support these enum variants (also a fairly trivial change)?
</content>
</entry>
<entry>
<title>Added LLVMRustRelocMode</title>
<updated>2017-04-28T22:33:56+00:00</updated>
<author>
<name>Amit Aryeh Levy</name>
<email>amit@amitlevy.com</email>
</author>
<published>2017-04-28T22:21:59+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=0f00f27e0d4743b14f7c0d0fca9731a45eae487a'/>
<id>urn:sha1:0f00f27e0d4743b14f7c0d0fca9731a45eae487a</id>
<content type='text'>
Replaces the llvm-c exposed LLVMRelocMode, which does not include all
relocation model variants, with a LLVMRustRelocMode modeled after
LLVMRustCodeMode.
</content>
</entry>
<entry>
<title>Add RWPI/ROPI relocation model support</title>
<updated>2017-04-26T20:25:14+00:00</updated>
<author>
<name>Amit Aryeh Levy</name>
<email>amit@amitlevy.com</email>
</author>
<published>2017-04-26T00:05:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=32b92669e4ec83005eff2641b092f25be09373b8'/>
<id>urn:sha1:32b92669e4ec83005eff2641b092f25be09373b8</id>
<content type='text'>
Adds support for using LLVM 4's ROPI and RWPI relocation models for ARM
</content>
</entry>
<entry>
<title>Add Hexagon support</title>
<updated>2017-04-25T05:56:44+00:00</updated>
<author>
<name>Michael Wu</name>
<email>mwu.code@gmail.com</email>
</author>
<published>2017-04-09T06:03:31+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=c558a2ae37052dc1f12aa4e40578eb4ae9aca3b9'/>
<id>urn:sha1:c558a2ae37052dc1f12aa4e40578eb4ae9aca3b9</id>
<content type='text'>
This requires an updated LLVM with D31999 and D32000 to build libcore.

A basic hello world builds and runs successfully on the hexagon simulator.
</content>
</entry>
<entry>
<title>Auto merge of #38745 - CannedYerins:llvm-code-style, r=rkruppe</title>
<updated>2017-01-01T11:58:02+00:00</updated>
<author>
<name>bors</name>
<email>bors@rust-lang.org</email>
</author>
<published>2017-01-01T11:58:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=ac5cd3bd43b9dbe681417e482065b24c08c544e8'/>
<id>urn:sha1:ac5cd3bd43b9dbe681417e482065b24c08c544e8</id>
<content type='text'>
Improve naming style in rustllvm.

As per the LLVM style guide, use CamelCase for all locals and classes,
and camelCase for all non-FFI functions.
Also, make names of variables of commonly used types more consistent.

Fixes #38688.

r? @rkruppe
</content>
</entry>
<entry>
<title>Merge branch 'master' into sparc64</title>
<updated>2017-01-01T03:40:10+00:00</updated>
<author>
<name>Seo Sanghyeon</name>
<email>sanxiyn@gmail.com</email>
</author>
<published>2017-01-01T03:40:10+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=b14785d3d0e3093983f6d6e266b754e1b536da10'/>
<id>urn:sha1:b14785d3d0e3093983f6d6e266b754e1b536da10</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Improve naming style in rustllvm.</title>
<updated>2016-12-31T18:20:30+00:00</updated>
<author>
<name>Ian Kerins</name>
<email>ianskerins@gmail.com</email>
</author>
<published>2016-12-31T17:01:23+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=e6f97114ca67ffcd55c81d990f1f239957eb6c00'/>
<id>urn:sha1:e6f97114ca67ffcd55c81d990f1f239957eb6c00</id>
<content type='text'>
As per the LLVM style guide, use CamelCase for all locals and classes,
and camelCase for all non-FFI functions.
Also, make names of variables of commonly used types more consistent.

Fixes #38688.
</content>
</entry>
<entry>
<title>Switching from NULL to nullptr in src/rustllvm.</title>
<updated>2016-12-30T15:37:05+00:00</updated>
<author>
<name>karpinski</name>
<email>marcinpkarpinski@gmail.com</email>
</author>
<published>2016-12-30T12:21:21+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=72ebc02f13eeb7328d199d7d5ccaee4e5ff03b3e'/>
<id>urn:sha1:72ebc02f13eeb7328d199d7d5ccaee4e5ff03b3e</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Ran clang-format on src/rustllvm with llvm as the coding style.</title>
<updated>2016-12-30T15:36:50+00:00</updated>
<author>
<name>karpinski</name>
<email>marcinpkarpinski@gmail.com</email>
</author>
<published>2016-12-30T11:22:11+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=c72d859e4f27c4b4c4be349091f5c71058ac1cd4'/>
<id>urn:sha1:c72d859e4f27c4b4c4be349091f5c71058ac1cd4</id>
<content type='text'>
</content>
</entry>
<entry>
<title>further enable the Sparc LLVM backend</title>
<updated>2016-12-30T02:30:01+00:00</updated>
<author>
<name>Jonathan A. Kollasch</name>
<email>jakllsch@kollasch.net</email>
</author>
<published>2016-12-03T16:53:31+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=982849535d42a675ba85ad2c07db229e2604fe5a'/>
<id>urn:sha1:982849535d42a675ba85ad2c07db229e2604fe5a</id>
<content type='text'>
</content>
</entry>
</feed>
