Update LLVM (#3502)

In llvm submodule: set branch to main, so can just update with:

$ git submodule update --remote --merge

See PR for summary of significant upstream changes and details of how they were handled:
https://github.com/llvm/circt/pull/3502
This commit is contained in:
Will Dietz 2022-07-18 14:18:53 -05:00 committed by GitHub
parent 939a6aa68b
commit 69a110f97f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
19 changed files with 16 additions and 25 deletions

1
.gitmodules vendored
View File

@ -2,3 +2,4 @@
path = llvm
url = https://github.com/llvm/llvm-project.git
shallow = true
branch = main

View File

@ -11,7 +11,7 @@
#ifndef CIRCT_C_DIALECT_COMB_H
#define CIRCT_C_DIALECT_COMB_H
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#ifdef __cplusplus
extern "C" {

View File

@ -11,7 +11,7 @@
#ifndef CIRCT_C_DIALECT_ESI_H
#define CIRCT_C_DIALECT_ESI_H
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#ifdef __cplusplus
extern "C" {

View File

@ -11,7 +11,7 @@
#ifndef CIRCT_C_DIALECT_FSM_H
#define CIRCT_C_DIALECT_FSM_H
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#ifdef __cplusplus
extern "C" {

View File

@ -18,7 +18,6 @@
#define CIRCT_C_DIALECT_HW_H
#include "mlir-c/IR.h"
#include "mlir-c/Registration.h"
#ifdef __cplusplus
extern "C" {

View File

@ -9,7 +9,7 @@
#ifndef CIRCT_C_DIALECT_LLHD_H
#define CIRCT_C_DIALECT_LLHD_H
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#ifdef __cplusplus
extern "C" {

View File

@ -14,7 +14,6 @@
#include "circt/Dialect/MSFT/MSFTDialect.h"
#include "mlir-c/IR.h"
#include "mlir-c/Pass.h"
#include "mlir-c/Registration.h"
#ifdef __cplusplus
extern "C" {

View File

@ -9,7 +9,7 @@
#ifndef CIRCT_C_DIALECT_MOORE_H
#define CIRCT_C_DIALECT_MOORE_H
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#ifdef __cplusplus
extern "C" {

View File

@ -11,7 +11,7 @@
#ifndef CIRCT_C_DIALECT_SV_H
#define CIRCT_C_DIALECT_SV_H
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#ifdef __cplusplus
extern "C" {

View File

@ -11,7 +11,7 @@
#ifndef CIRCT_C_DIALECT_SEQ_H
#define CIRCT_C_DIALECT_SEQ_H
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#ifdef __cplusplus
extern "C" {

View File

@ -130,7 +130,7 @@ class SV_Attr<string attrName, string attrMnemonic, list<Trait> traits = []>
def ModportStruct : SV_Attr<"ModportStruct", "mod_port"> {
let parameters = (ins
ModportDirectionAttr:$direction,
"::circt::sv::ModportDirectionAttr":$direction,
"mlir::FlatSymbolRefAttr":$signal);
let assemblyFormat = "`<` struct(params) `>`";

View File

@ -18,7 +18,7 @@
#include "circt-c/Dialect/Seq.h"
#include "circt-c/ExportVerilog.h"
#include "mlir-c/Bindings/Python/Interop.h"
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#include "mlir/Bindings/Python/PybindAdaptors.h"
#include "llvm-c/ErrorHandling.h"

View File

@ -43,9 +43,7 @@ void HWDialect::registerAttributes() {
Attribute HWDialect::parseAttribute(DialectAsmParser &p, Type type) const {
StringRef attrName;
Attribute attr;
if (p.parseKeyword(&attrName))
return Attribute();
auto parseResult = generatedAttributeParser(p, attrName, type, attr);
auto parseResult = generatedAttributeParser(p, &attrName, type, attr);
if (parseResult.hasValue())
return attr;

View File

@ -171,9 +171,7 @@ static ParseResult parseHWElementType(Type &result, AsmParser &p) {
typeString.startswith("uarray<") || typeString.startswith("struct<") ||
typeString.startswith("typealias<") || typeString.startswith("int<")) {
llvm::StringRef mnemonic;
if (p.parseKeyword(&mnemonic))
llvm_unreachable("should have an array or inout keyword here");
auto parseResult = generatedTypeParser(p, mnemonic, result);
auto parseResult = generatedTypeParser(p, &mnemonic, result);
return parseResult.hasValue() ? success() : failure();
}

View File

@ -1549,10 +1549,7 @@ static ParseResult parseMooreType(DialectAsmParser &parser, Subset subset,
Type &type) {
llvm::SMLoc loc = parser.getCurrentLocation();
StringRef mnemonic;
if (parser.parseKeyword(&mnemonic))
return failure();
OptionalParseResult result = generatedTypeParser(parser, mnemonic, type);
OptionalParseResult result = generatedTypeParser(parser, &mnemonic, type);
if (result.hasValue())
return result.getValue();

2
llvm

@ -1 +1 @@
Subproject commit dd74d3117de0fd96383beeb4b4b913efcb9f4328
Subproject commit bd228a17727ec0f51f8606bbcfb4fe65aebbd0dd

View File

@ -8,7 +8,6 @@ target_link_libraries(circt-capi-ir-test
PRIVATE
${dialect_libs}
MLIRCAPIRegistration
CIRCTCAPIComb
CIRCTCAPIHW
CIRCTCAPISeq

View File

@ -17,7 +17,7 @@
#include "mlir-c/AffineMap.h"
#include "mlir-c/BuiltinTypes.h"
#include "mlir-c/Diagnostics.h"
#include "mlir-c/Registration.h"
#include "mlir-c/IR.h"
#include <assert.h>
#include <math.h>

View File

@ -133,7 +133,7 @@ circuit invalid_bits :
module invalid_bits:
input a: UInt<8>
output b: UInt<4>
; expected-error@+1 {{high must be equal or greater than low, but got high = 4, low = 7}};
; expected-error @+1 {{high must be equal or greater than low, but got high = 4, low = 7}}
b <= bits(a, 4, 7)
;// -----