Skip to content

Commit

Permalink
Fix #633: Bump the LLVM version to 16.0.6. (#676)
Browse files Browse the repository at this point in the history
* Fix #633: Bump the LLVM version to 16.0.6.

This changes the internal llvm (tpls/llvm) to point to a SHA on the release/16.x
branch. This SHA corresponds to version 16.0.6.

Documentation should be updated to refer to LLVM 16.0.6 as the latest version
supported.

Add workaround for unsigned integer constants as template arguments.

Move the subdirectory up in the file to avoid it getting "lost". It's not clear
what the bug is towards the end of the file that was causing it to be omitted
in my workspace setup.

* Update lib/Frontend/nvqpp/ConvertDecl.cpp

Co-authored-by: Ben Howe <[email protected]>

---------

Co-authored-by: Ben Howe <[email protected]>
  • Loading branch information
schweitzpgi and bmhowe23 authored Sep 21, 2023
1 parent 7e55ee7 commit 0ae9f44
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
7 changes: 6 additions & 1 deletion lib/Frontend/nvqpp/ConvertDecl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,12 @@ bool QuakeBridgeVisitor::interceptRecordDecl(clang::RecordDecl *x) {
auto templArg = tempSpec->getTemplateArgs()[0];
assert(templArg.getKind() ==
clang::TemplateArgument::ArgKind::Integral);
std::int64_t size = templArg.getAsIntegral().getExtValue();
auto getExtValueHelper = [](auto v) -> std::int64_t {
if (v.isUnsigned())
return static_cast<std::int64_t>(v.getZExtValue());
return v.getSExtValue();
};
std::int64_t size = getExtValueHelper(templArg.getAsIntegral());
if (size != static_cast<std::int64_t>(std::dynamic_extent))
return pushType(quake::VeqType::get(ctx, size));
}
Expand Down
2 changes: 1 addition & 1 deletion tpls/llvm
Submodule llvm updated 5806 files
4 changes: 2 additions & 2 deletions unittests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,8 @@ target_link_libraries(test_spin
gtest_main)
gtest_discover_tests(test_spin)

add_subdirectory(plugin)

# build the test qudit execution manager
add_subdirectory(qudit)
add_executable(test_qudit main.cpp qudit/SimpleQuditTester.cpp)
Expand Down Expand Up @@ -183,5 +185,3 @@ if (CUDAQ_ENABLE_PYTHON)
TEST_SUFFIX _Sampling PROPERTIES ENVIRONMENT "PYTHONPATH=${CMAKE_BINARY_DIR}/python")
endif()

add_subdirectory(plugin)

0 comments on commit 0ae9f44

Please sign in to comment.