Brad Bishop | e42b3e3 | 2020-01-15 22:08:42 -0500 | [diff] [blame] | 1 | help complier to use intrinsics, clang in few cases e.g. aarch64 can not |
| 2 | and then requires linking with libm, its the only function needed from libm then |
| 3 | its good to avoid needing it. |
| 4 | |
| 5 | Upstream-Status: Pending |
| 6 | Signed-off-by: Khem Raj <raj.khem@gmail.com> |
| 7 | |
| 8 | --- a/include/fluent-bit/stream_processor/flb_sp_timeseries.h |
| 9 | +++ b/include/fluent-bit/stream_processor/flb_sp_timeseries.h |
| 10 | @@ -207,7 +207,7 @@ void cb_forecast_calc(struct timeseries |
| 11 | result = b0 + b1 * (val->f64 + *forecast->latest_x); |
| 12 | break; |
| 13 | default: |
| 14 | - result = nan(""); |
| 15 | + result = __builtin_nan(""); |
| 16 | break; |
| 17 | } |
| 18 | |
| 19 | @@ -283,7 +283,7 @@ void cb_forecast_r_calc(struct timeserie |
| 20 | result = ((val->i64 - b0) / b1) - *forecast->latest_x; |
| 21 | break; |
| 22 | default: |
| 23 | - result = nan(""); |
| 24 | + result = __builtin_nan(""); |
| 25 | break; |
| 26 | } |
| 27 | |