| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 228 } \ | 228 } \ |
| 229 virtual bool isMarked(const Type*) override { return false; } \ | 229 virtual bool isMarked(const Type*) override { return false; } \ |
| 230 virtual bool ensureMarked(const Type* objectPointer) override \ | 230 virtual bool ensureMarked(const Type* objectPointer) override \ |
| 231 { \ | 231 { \ |
| 232 return ensureMarked(objectPointer); \ | 232 return ensureMarked(objectPointer); \ |
| 233 } | 233 } |
| 234 | 234 |
| 235 class CountingVisitor : public Visitor { | 235 class CountingVisitor : public Visitor { |
| 236 public: | 236 public: |
| 237 CountingVisitor() | 237 CountingVisitor() |
| 238 : m_count(0) | 238 : Visitor(Visitor::GenericVisitorType) |
| 239 , m_count(0) |
| 239 { | 240 { |
| 240 } | 241 } |
| 241 | 242 |
| 242 virtual void mark(const void* object, TraceCallback) override | 243 virtual void mark(const void* object, TraceCallback) override |
| 243 { | 244 { |
| 244 if (object) | 245 if (object) |
| 245 m_count++; | 246 m_count++; |
| 246 } | 247 } |
| 247 | 248 |
| 248 virtual void mark(HeapObjectHeader* header, TraceCallback callback) override | 249 virtual void mark(HeapObjectHeader* header, TraceCallback callback) override |
| (...skipping 5091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5340 Heap::collectGarbage(ThreadState::NoHeapPointersOnStack); | 5341 Heap::collectGarbage(ThreadState::NoHeapPointersOnStack); |
| 5341 | 5342 |
| 5342 // Verify that the DeepEagerly chain isn't completely unravelled | 5343 // Verify that the DeepEagerly chain isn't completely unravelled |
| 5343 // by performing eager trace() calls, but the explicit mark | 5344 // by performing eager trace() calls, but the explicit mark |
| 5344 // stack is switched once some nesting limit is exceeded. | 5345 // stack is switched once some nesting limit is exceeded. |
| 5345 EXPECT_GT(DeepEagerly::sTraceLazy, 2); | 5346 EXPECT_GT(DeepEagerly::sTraceLazy, 2); |
| 5346 #endif | 5347 #endif |
| 5347 } | 5348 } |
| 5348 | 5349 |
| 5349 } // namespace blink | 5350 } // namespace blink |
| OLD | NEW |