Skip to content
  1. Aug 22, 2013
  2. Aug 21, 2013
    • Rafael Espindola's avatar
      Move -mfpmath handling to -cc1 and implement it for x86. · eb265471
      Rafael Espindola authored
      The original idea was to implement it all on the driver, but to do that the
      driver needs to know the sse level and to do that it has to know the default
      features of a cpu.
      
      Benjamin Kramer pointed out that if one day we decide to implement support for
      ' __attribute__ ((__target__ ("arch=core2")))', then the frontend needs to
      keep its knowledge of default features of a cpu.
      
      To avoid duplicating which part of clang handles default cpu features,
      it is probably better to handle -mfpmath in the frontend.
      
      For ARM this patch is just a small improvement. Instead of a cpu list, we
      check if neon is enabled, which allows us to reject things like
      
      -mcpu=cortex-a9 -mfpu=vfp -mfpmath=neon
      
      For X86, since LLVM doesn't support an independent ssefp feature, we just
      make sure the selected -mfpmath matches the sse level.
      
      llvm-svn: 188939
      eb265471
Loading