Chromium Code Reviews| Index: src/platform-posix.cc |
| diff --git a/src/platform-posix.cc b/src/platform-posix.cc |
| index a729b662605ad1377395cf7f0fb9668d3863ce48..750b9117d96c79bd8742b224da9fadf6cc6e6ba3 100644 |
| --- a/src/platform-posix.cc |
| +++ b/src/platform-posix.cc |
| @@ -134,8 +134,10 @@ void init_fast_##name##_function() { \ |
| fast_##name##_function = generator; \ |
| } \ |
| double fast_##name(double x) { \ |
| - CallOnce(&fast_##name##_init_once, \ |
| - &init_fast_##name##_function); \ |
| + if (!fast_##name##_function) { \ |
|
danno
2012/03/29 07:45:17
Since this is also could be called frequently, per
Philippe
2012/03/29 09:00:48
I tried to do that initially by calling these init
danno
2012/03/29 09:07:20
Calling it from OS::PostSetUp seems fine. I would
Philippe
2012/03/29 09:26:53
Done.
|
| + CallOnce(&fast_##name##_init_once, \ |
| + &init_fast_##name##_function); \ |
| + } \ |
| return (*fast_##name##_function)(x); \ |
| } |