# Copyright (c) 2021-2022 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. #! CHECKER Irreduceble loop test #! RUN_PAOC options: "--compiler-regex=.*try_to_reproduce.*" #! RUN options: "", entry: "_GLOBAL::main", result: 1 #! EVENT /AotEntrypointFound,_GLOBAL::try_to_reproduce/ .function i32 try_to_reproduce(i32 a0, i32 a1, i32 a2, i32 a3) { lda a0 jeqz _08 jmp _03 _03: jmp _13 _08: lda a1 jeqz _12 jmp _11 _13: lda a2 jeqz _15 jmp _11 _15: jmp _12 _12: lda a3 jeqz _13 jmp _14 _11: return _14: return } .function i32 main() { movi v0, 0 movi v1, 1 movi v2, 2 movi v3, 3 call try_to_reproduce, v0, v1, v2, v3 return }