History log of /external/llvm/include/llvm/TableGen/Record.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
236bcf1fcd6164d624956c0858593c1a780b9a0b 09-Sep-2012 Aaron Ballman <aaron@aaronballman.com> Fixing a type width warning with MSVC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163481 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
307525cd24c3b9c081ddb3c34a3418f2875cd556 07-Sep-2012 Michael Liao <michael.liao@intel.com> Re-work bit/bits value resolving in tblgen

- This patch is inspired by the failure of the following code snippet
which is used to convert enumerable values into encoding bits to
improve the readability of td files.

class S<int s> {
bits<2> V = !if(!eq(s, 8), {0, 0},
!if(!eq(s, 16), {0, 1},
!if(!eq(s, 32), {1, 0},
!if(!eq(s, 64), {1, 1}, {?, ?}))));
}

Later, PR8330 is found to report not exactly the same bug relevant
issue to bit/bits values.

- Instead of resolving bit/bits values separately through
resolveBitReference(), this patch adds getBit() for all Inits and
resolves bit value by resolving plus getting the specified bit. This
unifies the resolving of bit with other values and removes redundant
logic for resolving bit only. In addition,
BitsInit::resolveReferences() is optimized to take advantage of this
origanization by resolving VarBitInit's variable reference first and
then getting bits from it.

- The type interference in '!if' operator is revised to support possible
combinations of int and bits/bit in MHS and RHS.

- As there may be illegal assignments from integer value to bit, says
assign 2 to a bit, but we only check this during instantiation in some
cases, e.g.

bit V = !if(!eq(x, 17), 0, 2);

Verbose diagnostic message is generated when invalid value is
resolveed to help locating the error.

- PR8330 is fixed as well.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163360 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
c1f10fd5b9a780d1c42dca7143d7a8acd9bd9377 23-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Tristate mayLoad, mayStore, and hasSideEffects.

Keep track of the set/unset state of these bits along with their
true/false values, but treat '?' as '0' for now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162461 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
376a8a773e38fdcd9102a40e08ab1e0661d645d9 23-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Print out the location of expanded multiclass defs in TableGen errors.

When reporting an error for a defm, we would previously only report the
location of the outer defm, which is not always where the error is.

Now we also print the location of the expanded multiclass defs:

lib/Target/X86/X86InstrSSE.td:2902:12: error: foo
defm ADD : basic_sse12_fp_binop_s<0x58, "add", fadd, SSE_ALU_ITINS_S>,
^
lib/Target/X86/X86InstrSSE.td:2801:11: note: instantiated from multiclass
defm PD : sse12_fp_packed<opc, !strconcat(OpcodeStr, "pd"), OpNode, VR128,
^
lib/Target/X86/X86InstrSSE.td:194:5: note: instantiated from multiclass
def rm : PI<opc, MRMSrcMem, (outs RC:$dst), (ins RC:$src1, x86memop:$src2),
^

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162409 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
72cba6cdf640411e2fb6207858a0abd87c4286fc 25-May-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Don't put TGParser scratch results in the output.

Only fully expanded Records should go into RecordKeeper.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@157431 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
4b18691c3580674691875ec37c84a1c4edf2d586 18-Apr-2012 Jim Grosbach <grosbach@apple.com> Tidy up. Trailing whitespace.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@155013 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
cebb4ee93a0064e4a2cb1fd1da7455b01e5655cb 22-Feb-2012 David Greene <greened@obbligato.org> Add Foreach Loop

Add some data structures to represent for loops. These will be
referenced during object processing to do any needed iteration and
instantiation.

Add foreach keyword support to the lexer.

Add a mode to indicate that we're parsing a foreach loop. This allows
the value parser to early-out when processing the foreach value list.

Add a routine to parse foreach iteration declarations. This is
separate from ParseDeclaration because the type of the named value
(the iterator) doesn't match the type of the initializer value (the
value list). It also needs to add two values to the foreach record:
the iterator and the value list.

Add parsing support for foreach.

Add the code to process foreach loops and create defs based
on iterator values.

Allow foreach loops to be matched at the top level.

When parsing an IDValue check if it is a foreach loop iterator for one
of the active loops. If so, return a VarInit for it.

Add Emacs keyword support for foreach.

Add VIM keyword support for foreach.

Add tests to check foreach operation.

Add TableGen documentation for foreach.

Support foreach with multiple objects.

Support non-braced foreach body with one object.

Do not require types for the foreach declaration. Assume the iterator
type from the iteration list element type.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@151164 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
50bee42b54cd9aec5f49566307df2b0cf23afcf6 05-Feb-2012 Craig Topper <craig.topper@gmail.com> Convert assert(0) to llvm_unreachable

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149849 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
8dd6f0c8353f80de6526810899f271d539f6929c 13-Jan-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Delete CodeInit and CodeRecTy from TableGen.

The code type was always identical to a string anyway. Now it is simply
a synonym. The code literal syntax [{...}] is still valid.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148092 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
ebaf92c67dac4974f98a08f8096d3eb2f4edd09d 13-Jan-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Use uniqued StringInit pointers for lookups.

This avoids a gazillion StringMap and dynamic_cast calls, making
TableGen run 3x faster.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148091 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
2d24e2a396a1d211baaeedf32148a3b657240170 20-Dec-2011 David Blaikie <dblaikie@gmail.com> Unweaken vtables as per http://llvm.org/docs/CodingStandards.html#ll_virtual_anch

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146960 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
e338565757bfcfe9d762751c976684f66954fb45 19-Oct-2011 David Greene <greened@obbligato.org> Add NAME Member

Add a Value named "NAME" to each Record. This will be set to the def or defm
name when instantiating multiclasses. This will replace the #NAME# processing
hack once paste functionality is in place.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142518 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
004adaf3452a355ada2a54bcb61dc8925a718651 19-Oct-2011 David Greene <greened@obbligato.org> Call Record Initializer

Call the common Record initializer code from constructors.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142509 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
675f85d0f240930d571f4e557bb92237ee48124e 19-Oct-2011 David Greene <greened@obbligato.org> Add Name Init Record Constructor

Add a Record constructor that takes the Record name as an Init. This
is more work toward paste functionality.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142508 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
0abdadbce7e04af76145154d75ca41dab749b8d6 19-Oct-2011 David Greene <greened@obbligato.org> Fix 80-col Violation

Split up the initializer list for Record to avoid 80-col issues.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142507 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
0615d6aac810059a37fbced0f315cce75476da49 19-Oct-2011 David Greene <greened@obbligato.org> Fix Name Check

Avoid a potential assert by asking for record names as strings explicitly.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142503 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
7474c29d903d479e7f99eb0d1d097f75289c5f48 19-Oct-2011 David Greene <greened@obbligato.org> Fix Name Check

Record names may not be fully resolved at this point so ask for the
record name as a string explicitly. This avoids a potential assert.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142502 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
f7931b7040de1c829e678b4e391308bc3376f8a0 19-Oct-2011 David Greene <greened@obbligato.org> Add Record Init

Add an init function to be shared among Record constructors.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142501 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
e22b321d2276b634519165b101b02d92c2fcf5c7 19-Oct-2011 David Greene <greened@obbligato.org> Make Template Arg Names Inits

Allow template arg names to be Inits. This is further work to
implement paste as it allows template names to participate in paste
operations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142500 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
30c2225b3c4a89b527ee38542ab8990ca0a682f1 19-Oct-2011 David Greene <greened@obbligato.org> Add Utility to Scope Names

Add a couple of utility functions to take a variable name and qualify
it with the namespace of the enclosing class and/or multiclass. This
is inpreparation for making template arg names first-class Inits.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142498 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
ee6dca17252de152720655282fb4b74b76fb2fe9 19-Oct-2011 David Greene <greened@obbligato.org> Make VarInit Name an Init

Make the VarInit name an Init itself. We need this to implement paste
functionality so we can reference variables whose names are not yet
completely resolved.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142497 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
96a9f78c4aa1bc188f3f7ee869bed44cb7a6ff0e 19-Oct-2011 David Greene <greened@obbligato.org> Add Value Accessors

Add accessors to get Record values by Init name. This lets us look up
Record values whose names are not yet fully resolved. More work
toward paste.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142496 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
d7f8941e77fef20dc147fe102a2024cc5ccef366 19-Oct-2011 David Greene <greened@obbligato.org> Add Name Init Accessors

Add a utility to get the name init and get the string representation
of the name. This will be used for paste functionality.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142495 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
de703e25fe98f7c0dfab1750cf337a013b5c9603 19-Oct-2011 David Greene <greened@obbligato.org> Add Init Accessors

Add a couple of utility functions to get at the name init and return
the name init as a string. This will be used for paste functionality.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142494 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
a1b1b79be15c4b79a4282f148085ebad1cf877ca 07-Oct-2011 David Greene <greened@obbligato.org> Remove Multidefs

Multidefs are a bit unwieldy and incomplete. Remove them in favor of
another mechanism, probably for loops.

Revert "Make Test More Thorough"
Revert "Fix a typo."
Revert "Vim Support for Multidefs"
Revert "Emacs Support for Multidefs"
Revert "Document Multidefs"
Revert "Add a Multidef Test"
Revert "Update Test for Multidefs"
Revert "Process Multidefs"
Revert "Parser Multidef Support"
Revert "Lexer Support for Multidefs"
Revert "Add Multidef Data Structures"

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141378 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
bda579b8bab763f0b741c5775350cda09a394115 06-Oct-2011 David Greene <greened@obbligato.org> Add Multidef Data Structures

Add a set of data structures and members analogous to those used for
multiclass defs. These will represent a new kind of multiclass def: a
multidef. The idea behind the multidef is to process a list of items
and create a def record for each one inside the enclosing multiclass.
This allows the user to dynamically create a set of defs based on the
contents of a list.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141230 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h
7c788888872233748da10a8177a9a1eb176c1bc8 01-Oct-2011 Peter Collingbourne <peter@pcc.me.uk> Move TableGen's parser and entry point into a library

This is the first step towards splitting LLVM and Clang's tblgen executables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140951 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/TableGen/Record.h