| OLD | NEW |
| 1 // Copyright 2006-2009 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2009 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 4902 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4913 return Heap::null_value(); | 4913 return Heap::null_value(); |
| 4914 } | 4914 } |
| 4915 } | 4915 } |
| 4916 | 4916 |
| 4917 | 4917 |
| 4918 static Object* Runtime_DateLocalTimezone(Arguments args) { | 4918 static Object* Runtime_DateLocalTimezone(Arguments args) { |
| 4919 NoHandleAllocation ha; | 4919 NoHandleAllocation ha; |
| 4920 ASSERT(args.length() == 1); | 4920 ASSERT(args.length() == 1); |
| 4921 | 4921 |
| 4922 CONVERT_DOUBLE_CHECKED(x, args[0]); | 4922 CONVERT_DOUBLE_CHECKED(x, args[0]); |
| 4923 char* zone = OS::LocalTimezone(x); | 4923 const char* zone = OS::LocalTimezone(x); |
| 4924 return Heap::AllocateStringFromUtf8(CStrVector(zone)); | 4924 return Heap::AllocateStringFromUtf8(CStrVector(zone)); |
| 4925 } | 4925 } |
| 4926 | 4926 |
| 4927 | 4927 |
| 4928 static Object* Runtime_DateLocalTimeOffset(Arguments args) { | 4928 static Object* Runtime_DateLocalTimeOffset(Arguments args) { |
| 4929 NoHandleAllocation ha; | 4929 NoHandleAllocation ha; |
| 4930 ASSERT(args.length() == 0); | 4930 ASSERT(args.length() == 0); |
| 4931 | 4931 |
| 4932 return Heap::NumberFromDouble(OS::LocalTimeOffset()); | 4932 return Heap::NumberFromDouble(OS::LocalTimeOffset()); |
| 4933 } | 4933 } |
| (...skipping 2667 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7601 } else { | 7601 } else { |
| 7602 // Handle last resort GC and make sure to allow future allocations | 7602 // Handle last resort GC and make sure to allow future allocations |
| 7603 // to grow the heap without causing GCs (if possible). | 7603 // to grow the heap without causing GCs (if possible). |
| 7604 Counters::gc_last_resort_from_js.Increment(); | 7604 Counters::gc_last_resort_from_js.Increment(); |
| 7605 Heap::CollectAllGarbage(); | 7605 Heap::CollectAllGarbage(); |
| 7606 } | 7606 } |
| 7607 } | 7607 } |
| 7608 | 7608 |
| 7609 | 7609 |
| 7610 } } // namespace v8::internal | 7610 } } // namespace v8::internal |
| OLD | NEW |