| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 // the platform dependent classes could have been implemented using abstract | 37 // the platform dependent classes could have been implemented using abstract |
| 38 // superclasses with virtual methods and having specializations for each | 38 // superclasses with virtual methods and having specializations for each |
| 39 // platform. This design was rejected because it was more complicated and | 39 // platform. This design was rejected because it was more complicated and |
| 40 // slower. It would require factory methods for selecting the right | 40 // slower. It would require factory methods for selecting the right |
| 41 // implementation and the overhead of virtual methods for performance | 41 // implementation and the overhead of virtual methods for performance |
| 42 // sensitive like mutex locking/unlocking. | 42 // sensitive like mutex locking/unlocking. |
| 43 | 43 |
| 44 #ifndef V8_PLATFORM_H_ | 44 #ifndef V8_PLATFORM_H_ |
| 45 #define V8_PLATFORM_H_ | 45 #define V8_PLATFORM_H_ |
| 46 | 46 |
| 47 #define ATOMICOPS_COMPILER_BARRIER() __asm__ __volatile__("" : : : "memory") |
| 48 |
| 47 #ifdef __sun | 49 #ifdef __sun |
| 48 # ifndef signbit | 50 # ifndef signbit |
| 49 int signbit(double x); | 51 int signbit(double x); |
| 50 # endif | 52 # endif |
| 51 #endif | 53 #endif |
| 52 | 54 |
| 53 // GCC specific stuff | 55 // GCC specific stuff |
| 54 #ifdef __GNUC__ | 56 #ifdef __GNUC__ |
| 55 | 57 |
| 56 // Needed for va_list on at least MinGW and Android. | 58 // Needed for va_list on at least MinGW and Android. |
| (...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 757 Atomic32 active_; | 759 Atomic32 active_; |
| 758 PlatformData* data_; // Platform specific data. | 760 PlatformData* data_; // Platform specific data. |
| 759 int samples_taken_; // Counts stack samples taken. | 761 int samples_taken_; // Counts stack samples taken. |
| 760 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); | 762 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); |
| 761 }; | 763 }; |
| 762 | 764 |
| 763 | 765 |
| 764 } } // namespace v8::internal | 766 } } // namespace v8::internal |
| 765 | 767 |
| 766 #endif // V8_PLATFORM_H_ | 768 #endif // V8_PLATFORM_H_ |
| OLD | NEW |