History log of /llvm-project-15.0.7/llvm/lib/TableGen/Record.cpp (Results 1 – 25 of 263)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: llvmorg-20.1.0, llvmorg-20.1.0-rc3, llvmorg-20.1.0-rc2, llvmorg-20.1.0-rc1, llvmorg-21-init, llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4, llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4, llvmorg-19.1.0-rc3, llvmorg-19.1.0-rc2, llvmorg-19.1.0-rc1, llvmorg-20-init, llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5, llvmorg-18.1.4, llvmorg-18.1.3, llvmorg-18.1.2, llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init, llvmorg-16.0.6, llvmorg-16.0.5, llvmorg-16.0.4, llvmorg-16.0.3, llvmorg-16.0.2, llvmorg-16.0.1, llvmorg-16.0.0, llvmorg-16.0.0-rc4, llvmorg-16.0.0-rc3, llvmorg-16.0.0-rc2, llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7, llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init
# 394a388d 20-Jul-2022 Roman Rusyaev <[email protected]>

[TableGen] Add a location for a class definition that was forward-declared

This change improves ctags generation for tablegen files.

For the following example
```
class A;

class A {
int a;
}
```

[TableGen] Add a location for a class definition that was forward-declared

This change improves ctags generation for tablegen files.

For the following example
```
class A;

class A {
int a;
}
```
Previously, tags were generated only for a forward declaration of class 'A'.

This patch allows generating tags for the forward declarations
and further definition of class 'A'.

Reviewed By: barannikov88

Original patch by: rusyaev-roman (Roman Rusyaev)
Some adjustments by: nhaehnle (Nicolai Hähnle)

Differential Revision: https://reviews.llvm.org/D129935

show more ...


# 611ffcf4 14-Jul-2022 Kazu Hirata <[email protected]>

[llvm] Use value instead of getValue (NFC)


# a7938c74 26-Jun-2022 Kazu Hirata <[email protected]>

[llvm] Don't use Optional::hasValue (NFC)

This patch replaces Optional::hasValue with the implicit cast to bool
in conditionals only.


# 3b7c3a65 25-Jun-2022 Kazu Hirata <[email protected]>

Revert "Don't use Optional::hasValue (NFC)"

This reverts commit aa8feeefd3ac6c78ee8f67bf033976fc7d68bc6d.


# aa8feeef 25-Jun-2022 Kazu Hirata <[email protected]>

Don't use Optional::hasValue (NFC)


# 63448488 23-Jun-2022 wangpc <[email protected]>

[TableGen] Add new operator !exists

We can cast a string to a record via !cast, but we have no mechanism
to check if it is valid and TableGen will raise an error if failed to
cast. Besides, we have

[TableGen] Add new operator !exists

We can cast a string to a record via !cast, but we have no mechanism
to check if it is valid and TableGen will raise an error if failed to
cast. Besides, we have no semantic null in TableGen (we have `?` but
different backends handle uninitialized value differently), so operator
like `dyn_cast<>` is hard to implement.

In this patch, we add a new operator `!exists<T>(s)` to check whether
a record with type `T` and name `s` exists. Self-references are allowed
just like `!cast`.

By doing these, we can write code like:
```
class dyn_cast_to_record<string name> {
R value = !if(!exists<R>(name), !cast<R>(name), default_value);
}
defvar v = dyn_cast_to_record<"R0">.value; // R0 or default_value.
```

Reviewed By: tra, nhaehnle

Differential Revision: https://reviews.llvm.org/D127948

show more ...


Revision tags: llvmorg-14.0.6, llvmorg-14.0.5
# fb67d683 25-May-2022 serge-sans-paille <[email protected]>

[iwyu] Handle regressions in libLLVM header include

Running iwyu-diff on LLVM codebase since 7030654296a0416bd9402a0278 detected a few
regressions, fixing them.

Differential Revision: https://revie

[iwyu] Handle regressions in libLLVM header include

Running iwyu-diff on LLVM codebase since 7030654296a0416bd9402a0278 detected a few
regressions, fixing them.

Differential Revision: https://reviews.llvm.org/D126417

show more ...


Revision tags: llvmorg-14.0.4
# 2ac3cd20 07-May-2022 River Riddle <[email protected]>

[TableGen] Remove the use of global Record state

This commits removes TableGens reliance on managed static global record state
by moving the RecordContext into the RecordKeeper. The RecordKeeper is

[TableGen] Remove the use of global Record state

This commits removes TableGens reliance on managed static global record state
by moving the RecordContext into the RecordKeeper. The RecordKeeper is now
treated similarly to a (LLVM|MLIR|etc)Context object and is passed to static
construction functions. This is an important step forward in removing TableGens
reliance on global state, and in a followup will allow for users that parse tablegen
to parse multiple tablegen files without worrying about Record lifetime.

Differential Revision: https://reviews.llvm.org/D125276

show more ...


Revision tags: llvmorg-14.0.3, llvmorg-14.0.2, llvmorg-14.0.1, llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2, llvmorg-14.0.0-rc1, llvmorg-15-init
# 1d7120c6 28-Jan-2022 River Riddle <[email protected]>

[mlir] Split out AttrDef/TypeDef and pattern constructs from OpBase.td

OpBase.td has formed into a huge monolith of all ODS constructs. This
commits starts to rectify that by splitting out some cons

[mlir] Split out AttrDef/TypeDef and pattern constructs from OpBase.td

OpBase.td has formed into a huge monolith of all ODS constructs. This
commits starts to rectify that by splitting out some constructs to their
own .td files.

Differential Revision: https://reviews.llvm.org/D118636

show more ...


# e865fa75 15-Feb-2022 River Riddle <[email protected]>

[TableGen] Add a library-based entry point for parsing td files

This commit adds a new `TableGenParseFile` entry point for tablegen
that parses an input buffer and invokes a callback function with
a

[TableGen] Add a library-based entry point for parsing td files

This commit adds a new `TableGenParseFile` entry point for tablegen
that parses an input buffer and invokes a callback function with
a record keeper (notably without an output buffer). This kind of entry
point is very useful for tablegen consuming tools that don't create
output, and want invoke tablegen multiple times. The current way
that we interact with tablegen is via relative includes to
TGParser(not great).

Differential Revision: https://reviews.llvm.org/D119899

show more ...


# 92f49b89 28-Jan-2022 serge-sans-paille <[email protected]>

Cleanup include dependencies for LLVMTableGen

Based on the output of include-what-you-use. No other library seems affected by
the new forward declaration.

$ clang++ -E -Iinclude -I../llvm/include

Cleanup include dependencies for LLVMTableGen

Based on the output of include-what-you-use. No other library seems affected by
the new forward declaration.

$ clang++ -E -Iinclude -I../llvm/include ../llvm/lib/TableGen/*.cpp -std=c++14 -fno-rtti -fno-exceptions | wc -l
before: 795231
after: 750654

Related Discourse thread: https://llvm.discourse.group/t/include-what-you-use-include-cleanup
Differential Revision: https://reviews.llvm.org/D118374

show more ...


Revision tags: llvmorg-13.0.1, llvmorg-13.0.1-rc3, llvmorg-13.0.1-rc2, llvmorg-13.0.1-rc1
# 7480efd6 09-Nov-2021 River Riddle <[email protected]>

[Tablegen] Collect all global state into one managed static

Tablegen uses copious amounts of global state for uniquing various records.
This was fine under the original vision where tablegen was a t

[Tablegen] Collect all global state into one managed static

Tablegen uses copious amounts of global state for uniquing various records.
This was fine under the original vision where tablegen was a tool, and not a
library, but there are various usages of tablegen that want to use it as a library.
One concrete example is that downstream we have a kythe indexer for tablegen
constructs that allows for IDEs to serve go-to-definition/references/and more.
We currently (kind of hackily) keep the tablegen parts in a shared library that
gets loaded/unloaded.

This revision starts to remedy this by globbing all of the static state into a
managed static so that they can at least be unloaded with llvm_shutdown.
A better solution would be to feed in a context variable (much like how
the IR in LLVM/MLIR do), but that is a more invasive change that can come later.

Differential Revision: https://reviews.llvm.org/D108934

show more ...


# d968b173 03-Nov-2021 Cullen Rhodes <[email protected]>

[TableGen] Emit a warning for unused template args

Add a warning to TableGen for unused template arguments in classes and
multiclasses, for example:

multiclass Foo<int x> {
def bar;
}

$

[TableGen] Emit a warning for unused template args

Add a warning to TableGen for unused template arguments in classes and
multiclasses, for example:

multiclass Foo<int x> {
def bar;
}

$ llvm-tblgen foo.td

foo.td:1:20: warning: unused template argument: Foo::x
multiclass Foo<int x> {
^
A flag '--no-warn-on-unused-template-args' is added to disable the
warning. The warning is disabled for LLVM and sub-projects if
'LLVM_ENABLE_WARNINGS=OFF'.

Reviewed By: RKSimon

Differential Revision: https://reviews.llvm.org/D109359

show more ...


Revision tags: llvmorg-13.0.0, llvmorg-13.0.0-rc4
# e4b2f66d 16-Sep-2021 Simon Pilgrim <[email protected]>

[TableGen] Record::checkRecordAssertions() - Use const-ref iterator in for-range loop. NFCI.

Avoid unnecessary copies, reported by MSVC static analyzer.


Revision tags: llvmorg-13.0.0-rc3, llvmorg-13.0.0-rc2, llvmorg-13.0.0-rc1, llvmorg-14-init, llvmorg-12.0.1, llvmorg-12.0.1-rc4, llvmorg-12.0.1-rc3, llvmorg-12.0.1-rc2
# ef8df920 07-Jun-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Fix ProfileFoldOpInit so that parameters are named consistently [NFC]

See https://bugs.llvm.org/show_bug.cgi?id=50595

Differential Revision: https://reviews.llvm.org/D103823


Revision tags: llvmorg-12.0.1-rc1
# 952c6ddd 26-Apr-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Add the !find bang operator

!find searches a source string for a target string and returns the position.

Differential Revision: https://reviews.llvm.org/D101318


# 2d4c4d3c 20-Apr-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Change assertion information from a tuple to a struct [NFC]

Differential Revision: https://reviews.llvm.org/D100854


Revision tags: llvmorg-12.0.0, llvmorg-12.0.0-rc5
# a5aaec8f 01-Apr-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Add support for the 'assert' statement in multiclasses

This is step 3 of adding the 'assert' statement.

Differential Revision: https://reviews.llvm.org/D99751


# be50657c 13-Apr-2021 Daniel Sanders <[email protected]>

[TableGen] Resolve concrete but not complete field access initializers

This fixes the resolution of Rec10.Zero in ListSlices.td.

As part of this, correct the definition of complete for ListInit suc

[TableGen] Resolve concrete but not complete field access initializers

This fixes the resolution of Rec10.Zero in ListSlices.td.

As part of this, correct the definition of complete for ListInit such that
it's complete iff all the elements in the list are complete rather than
always being complete regardless of the elements. This is the reason
Rec10.TwoFive from ListSlices.td previously resolved despite being
incomplete like Rec10.Zero was

Depends on D100247

Reviewed By: Paul-C-Anagnostopoulos

Differential Revision: https://reviews.llvm.org/D100253

show more ...


# 489cdedd 09-Apr-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Fix bug in recent change to ListInit::convertInitListSlice()

Differential Revision: https://reviews.llvm.org/D100247


# 3f919ff2 08-Apr-2021 Paul C. Anagnostopoulos <[email protected]>

Revert "[TableGen] Add support for the 'assert' statement in multiclasses"

This reverts commit 3b9a15d910a8c748b1444333a4a3905a996528bc.


# 14580ce2 05-Apr-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Make behavior of list slice suffix consistent across all values

Differential Revision: https://reviews.llvm.org/D99883


# 3b9a15d9 01-Apr-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Add support for the 'assert' statement in multiclasses


Revision tags: llvmorg-12.0.0-rc4
# 5f473a04 22-Mar-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Add support for the 'assert' statement in class definitions.

Differential Revision: https://reviews.llvm.org/D99275


Revision tags: llvmorg-12.0.0-rc3
# a9fc44c5 25-Feb-2021 Paul C. Anagnostopoulos <[email protected]>

[TableGen] Improve handling of template arguments

This requires changes to TableGen files and some C++ files due to
incompatible multiclass template arguments that slipped through
before the improve

[TableGen] Improve handling of template arguments

This requires changes to TableGen files and some C++ files due to
incompatible multiclass template arguments that slipped through
before the improved handling.

show more ...


1234567891011