[PATCH] D135097: Remove redundant option '-menable-unsafe-fp-math'.

Sterling Augustine via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Oct 14 15:47:52 PDT 2022


saugustine added a comment.

The newly added test func-attr.c fails when run in opt mode. If it is expected to run only at a certain optimization level, it should probably include that level in the test itself. I don't think it seriously blocks anything, but would be good to fix.

  /usr/local/google/home/saugustine/llvm/build/bin/clang -O2 -c -ffast-math -emit-llvm -S -o - /usr/local/google/home/saugustine/llvm/llvm-project/clang/test/CodeGen/func-attr.c  | /usr/local/google/home/saugustine/llvm/build/bin/FileCheck /usr/local/google/home/saugustine/llvm/llvm-project/clang/test/CodeGen/func-attr.c
  /usr/local/google/home/saugustine/llvm/llvm-project/clang/test/CodeGen/func-attr.c:11:11: error: CHECK: expected string not found in input
  // CHECK: define{{.*}} float @foo(float noundef %a, float noundef %b) [[FAST_ATTRS:#[0-9]+]]
            ^
  <stdin>:1:1: note: scanning from here
  ; ModuleID = '/usr/local/google/home/saugustine/llvm/llvm-project/clang/test/CodeGen/func-attr.c'
  ^
  <stdin>:7:1: note: possible intended match here
  define dso_local float @foo(float noundef %a, float noundef %b) local_unnamed_addr #0 {
  ^
  
  Input file: <stdin>
  Check file: /usr/local/google/home/saugustine/llvm/llvm-project/clang/test/CodeGen/func-attr.c
  
  -dump-input=help explains the following input dump.
  
  Input was:
  <<<<<<
              1: ; ModuleID = '/usr/local/google/home/saugustine/llvm/llvm-project/clang/test/CodeGen/func-attr.c' 
  check:11'0     X~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ error: no match found
              2: source_filename = "/usr/local/google/home/saugustine/llvm/llvm-project/clang/test/CodeGen/func-attr.c" 
  check:11'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
              3: target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" 
  check:11'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
              4: target triple = "x86_64-unknown-linux-gnu" 
  check:11'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
              5:  
  check:11'0     ~
              6: ; Function Attrs: mustprogress nofree norecurse nosync nounwind readnone willreturn uwtable 
  check:11'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
              7: define dso_local float @foo(float noundef %a, float noundef %b) local_unnamed_addr #0 { 
  check:11'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  check:11'1     ?                                                                                        possible intended match
              8: entry: 
  check:11'0     ~~~~~~~
              9:  %add = fadd fast float %b, %a 
  check:11'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
             10:  ret float %add 
  check:11'0     ~~~~~~~~~~~~~~~~
             11: } 
  check:11'0     ~~
             12:  
  check:11'0     ~
              .
              .
              .
  >>>>>>


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D135097/new/

https://reviews.llvm.org/D135097



More information about the cfe-commits mailing list