Skip to content
  • Daniel Dunbar's avatar
    Support IRgen of sqrt -> llvm.sqrt, pow -> llvm.pow. · 8eb018ab
    Daniel Dunbar authored
     - Define pow[lf]?, sqrt[lf]? as builtins.
    
     - Add -fmath-errno option which binds to LangOptions.MathErrno
    
     - Add new builtin flag Builtin::Context::isConstWithoutErrno for
       functions which can be marked as const if errno isn't respected for
       math functions. Sema automatically marks these functions as const
       when they are defined, if MathErrno=0.
    
     - IRgen uses const attribute on sqrt and pow library functions to
       decide if it can use the llvm intrinsic.
    
    llvm-svn: 64689
    8eb018ab
Loading