Skip to content

Commit f4ca41a

Browse files
author
Kim Barrett
committed
8322816: RISC-V: Incorrect guarantee in patch_vtype
Reviewed-by: fyang, luhenry
1 parent 376051a commit f4ca41a

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/hotspot/cpu/riscv/assembler_riscv.hpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1997, 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1997, 2024, Oracle and/or its affiliates. All rights reserved.
33
* Copyright (c) 2014, 2020, Red Hat Inc. All rights reserved.
44
* Copyright (c) 2020, 2023, Huawei Technologies Co., Ltd. All rights reserved.
55
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -1156,10 +1156,8 @@ static Assembler::SEW elemtype_to_sew(BasicType etype) {
11561156
}
11571157

11581158
#define patch_vtype(hsb, lsb, vlmul, vsew, vta, vma, vill) \
1159-
if (vill == 1) { \
1160-
guarantee((vlmul | vsew | vta | vma == 0), \
1161-
"the other bits in vtype shall be zero"); \
1162-
} \
1159+
/* If vill then other bits of vtype must be zero. */ \
1160+
guarantee(!vill, "vill not supported"); \
11631161
patch((address)&insn, lsb + 2, lsb, vlmul); \
11641162
patch((address)&insn, lsb + 5, lsb + 3, vsew); \
11651163
patch((address)&insn, lsb + 6, vta); \

0 commit comments

Comments
 (0)