Skip to content

Commit 7e05566

Browse files
HEIR Teamcopybara-github
authored andcommitted
Updates LLVM usage to match [68c04b0ae62d](llvm/llvm-project@68c04b0ae62d) PiperOrigin-RevId: 682297340
1 parent 116c457 commit 7e05566

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

bazel/import_llvm.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ load(
77

88
def import_llvm(name):
99
"""Imports LLVM."""
10-
LLVM_COMMIT = "00128a20eec27246719d73ba427bf821883b00b4"
10+
LLVM_COMMIT = "68c04b0ae62d8431d72d8b47fc13008002ee4387"
1111

1212
new_git_repository(
1313
name = name,

tools/heir-opt.cpp

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@
6262
#include "lib/Transforms/Secretize/Passes.h"
6363
#include "lib/Transforms/StraightLineVectorizer/StraightLineVectorizer.h"
6464
#include "lib/Transforms/UnusedMemRef/UnusedMemRef.h"
65+
#include "llvm/include/llvm/ADT/SmallVector.h" // from @llvm-project
6566
#include "llvm/include/llvm/Support/CommandLine.h" // from @llvm-project
6667
#include "llvm/include/llvm/Support/raw_ostream.h" // from @llvm-project
6768
#include "mlir/include/mlir/Conversion/AffineToStandard/AffineToStandard.h" // from @llvm-project
@@ -325,7 +326,7 @@ void tosaToBooleanTfhePipeline(const std::string &yosysFilesPath,
325326
// Wrap with secret.generic and then distribute-generic.
326327
pm.addPass(createWrapGeneric());
327328
auto distributeOpts = secret::SecretDistributeGenericOptions{
328-
.opsToDistribute = opsToDistribute};
329+
.opsToDistribute = llvm::to_vector(opsToDistribute)};
329330
pm.addPass(secret::createSecretDistributeGeneric(distributeOpts));
330331
pm.addPass(createCanonicalizerPass());
331332

@@ -418,7 +419,7 @@ void tosaToBooleanFpgaTfhePipeline(const std::string &yosysFilesPath,
418419

419420
pm.addPass(createWrapGeneric());
420421
auto distributeOpts = secret::SecretDistributeGenericOptions{
421-
.opsToDistribute = opsToDistribute};
422+
.opsToDistribute = llvm::to_vector(opsToDistribute)};
422423
pm.addPass(secret::createSecretDistributeGeneric(distributeOpts));
423424
pm.addPass(createCanonicalizerPass());
424425

@@ -502,7 +503,7 @@ void tosaToJaxitePipeline(const std::string &yosysFilesPath,
502503
// Cleanup
503504
pm.addPass(createMemrefGlobalReplacePass());
504505
arith::ArithIntNarrowingOptions arithOps;
505-
arithOps.bitwidthsSupported = bitWidths;
506+
arithOps.bitwidthsSupported = llvm::to_vector(bitWidths);
506507
pm.addPass(arith::createArithIntNarrowing(arithOps));
507508
pm.addPass(createCanonicalizerPass());
508509
pm.addPass(createSCCPPass());
@@ -513,7 +514,7 @@ void tosaToJaxitePipeline(const std::string &yosysFilesPath,
513514
// Wrap with secret.generic and then distribute-generic.
514515
pm.addPass(createWrapGeneric());
515516
auto distributeOpts = secret::SecretDistributeGenericOptions{
516-
.opsToDistribute = opsToDistribute};
517+
.opsToDistribute = llvm::to_vector(opsToDistribute)};
517518
pm.addPass(secret::createSecretDistributeGeneric(distributeOpts));
518519
pm.addPass(createCanonicalizerPass());
519520
// Booleanize and Yosys Optimize

0 commit comments

Comments
 (0)