1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00
llvm-mirror/test/Assembler/non-global-value-max-name-size.ll
Hasyimi Bahrudin aa98e6ea8a Fix non-global-value-max-name-size not considered by LLParser
`non-global-value-max-name-size` is used by `Value` to cap the length of local value name. However, this flag is not considered by `LLParser`, which leads to unexpected `use of undefined value error`. The fix is to move the responsibility of capping the length to `ValueSymbolTable`.

The test is the one provided by [[ https://bugs.llvm.org/show_bug.cgi?id=45899 | Mikael in the bug report ]].

Reviewed By: mehdi_amini

Differential Revision: https://reviews.llvm.org/D102707
2021-05-27 04:20:03 +00:00

11 lines
188 B
LLVM

; RUN: opt < %s -S -non-global-value-max-name-size=4
; Test that local value name lookup works if the name is capped
define void @f() {
bb0:
br label %testz
testz:
br label %testz
}