mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-01 00:25:01 +00:00
Force vectors to be a power of two in size
llvm-svn: 24265
This commit is contained in:
parent
6a14d020a3
commit
8a169a30ae
File diff suppressed because it is too large
Load Diff
@ -1107,12 +1107,12 @@ UpRTypes : '\\' EUINT64VAL { // Type UpReference
|
||||
}
|
||||
| '<' EUINT64VAL 'x' UpRTypes '>' { // Packed array type?
|
||||
const llvm::Type* ElemTy = $4->get();
|
||||
if ((unsigned)$2 != $2) {
|
||||
if ((unsigned)$2 != $2)
|
||||
ThrowException("Unsigned result not equal to signed result");
|
||||
}
|
||||
if(!ElemTy->isPrimitiveType()) {
|
||||
if (!ElemTy->isPrimitiveType())
|
||||
ThrowException("Elemental type of a PackedType must be primitive");
|
||||
}
|
||||
if (!isPowerOf2_32($2))
|
||||
ThrowException("Vector length should be a power of 2!");
|
||||
$$ = new PATypeHolder(HandleUpRefs(PackedType::get(*$4, (unsigned)$2)));
|
||||
delete $4;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user