1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 04:22:57 +02:00
llvm-mirror/test/Feature
Peter Collingbourne 837799f13b Prologue support
Patch by Ben Gamari!

This redefines the `prefix` attribute introduced previously and
introduces a `prologue` attribute.  There are a two primary usecases
that these attributes aim to serve,

  1. Function prologue sigils

  2. Function hot-patching: Enable the user to insert `nop` operations
     at the beginning of the function which can later be safely replaced
     with a call to some instrumentation facility

  3. Runtime metadata: Allow a compiler to insert data for use by the
     runtime during execution. GHC is one example of a compiler that
     needs this functionality for its tables-next-to-code functionality.

Previously `prefix` served cases (1) and (2) quite well by allowing the user
to introduce arbitrary data at the entrypoint but before the function
body. Case (3), however, was poorly handled by this approach as it
required that prefix data was valid executable code.

Here we redefine the notion of prefix data to instead be data which
occurs immediately before the function entrypoint (i.e. the symbol
address). Since prefix data now occurs before the function entrypoint,
there is no need for the data to be valid code.

The previous notion of prefix data now goes under the name "prologue
data" to emphasize its duality with the function epilogue.

The intention here is to handle cases (1) and (2) with prologue data and
case (3) with prefix data.

References
----------

This idea arose out of discussions[1] with Reid Kleckner in response to a
proposal to introduce the notion of symbol offsets to enable handling of
case (3).

[1] http://lists.cs.uiuc.edu/pipermail/llvmdev/2014-May/073235.html

Test Plan: testsuite

Differential Revision: http://reviews.llvm.org/D6454

llvm-svn: 223189
2014-12-03 02:08:38 +00:00
..
alias2.ll Allow alias to point to an arbitrary ConstantExpr. 2014-06-03 02:41:57 +00:00
aliases.ll Use "weak alias" instead of "alias weak" 2014-07-30 22:51:54 +00:00
alignment.ll
attributes.ll Modify the LLVM assembly output so that it uses references to represent function attributes. 2013-02-20 07:21:42 +00:00
basictest.ll
callingconventions.ll Parse 'ghccc' in .ll files as the GHC convention (cc 10) 2014-12-01 21:04:44 +00:00
calltest.ll
casttest.ll
cfgstructures.ll
cold.ll Add a new function attribute 'cold' to functions. 2013-05-24 12:26:52 +00:00
comdat.ll IR: Allow comdats to be applied to globals with internal linkage 2014-07-13 04:56:11 +00:00
const_pv.ll There was a switch fall-through in the parser for textual LLVM that caused 2013-01-07 13:32:38 +00:00
constexpr.ll
constpointer.ll
escaped_label.ll
exception.ll
float.ll
fold-fpcast.ll
forwardreftest.ll
global_pv.ll Tests: rewrite 'opt ... %s' to 'opt ... < %s' so that opt does not emit a ModuleID 2012-12-30 02:33:22 +00:00
global_section.ll
globalredefinition3.ll
globalvars.ll Fix a small bug in the parsing of anonymous globals. 2014-06-03 20:07:32 +00:00
indirectcall2.ll
indirectcall.ll
inlineasm.ll
instructions.ll [IR] Make {extract,insert}element accept an index of any integer type. 2014-05-01 22:12:39 +00:00
intrinsic-noduplicate.ll Expose "noduplicate" attribute as a property for intrinsics. 2014-03-18 23:51:07 +00:00
intrinsics.ll Change math intrinsic attributes from readonly to readnone. These 2014-03-06 00:18:15 +00:00
load_module.ll Remove "lto_on_osx" xfails, now that -rdynamic works on Darwin. 2013-08-04 23:55:24 +00:00
md_on_instruction.ll Revert "Revert "DI: Fold constant arguments into a single MDString"" 2014-10-03 20:01:09 +00:00
memorymarkers.ll
metadata.ll
minsize_attr.ll Modify the LLVM assembly output so that it uses references to represent function attributes. 2013-02-20 07:21:42 +00:00
NamedMDNode2.ll
NamedMDNode.ll
newcasts.ll Add addrspacecast instruction. 2013-11-15 01:34:59 +00:00
optnone-llc.ll [AArch64] Update test case to pass with post-RA MI scheduler. 2014-09-13 03:23:23 +00:00
optnone-opt.ll Disable most IR-level transform passes on functions marked 'optnone'. 2014-02-06 00:07:05 +00:00
optnone.ll The 'optnone' attribute means don't inline anything into this function 2013-11-18 21:44:03 +00:00
packed_struct.ll
packed.ll
paramattrs.ll
ppcld.ll
prefixdata.ll Implement function prefix data as an IR feature. 2013-09-16 01:08:15 +00:00
prologuedata.ll Prologue support 2014-12-03 02:08:38 +00:00
properties.ll Remove the dependent libraries feature. 2012-11-27 09:55:56 +00:00
prototype.ll
README.txt
recursivetype.ll
simplecalltest.ll
small.ll
smallest.ll
sparcld.ll
terminators.ll
testalloca.ll
testconstants.ll
testlogical.ll
testtype.ll
testvarargs.ll
undefined.ll
unreachable.ll
varargs_new.ll
varargs.ll
vector-cast-constant-exprs.ll
weak_constant.ll Delete -std-compile-opts. 2014-10-16 20:00:02 +00:00
weirdnames.ll
x86ld.ll

This directory contains test cases for individual source features of LLVM.
It is designed to make sure that the major components of LLVM support all of the
features of LLVM, for very small examples.  Entire programs should not go here.

Regression tests for individual bug fixes should go into the test/Regression dir.