Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Side by Side Diff: third_party/WebKit/Source/platform/heap/HeapPage.h

Issue 2629853002: Add NOTREACHED to HeapObjectHeader::markDead() (Closed)
Patch Set: temp Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 907 matching lines...) Expand 10 before | Expand all | Expand 10 after
918 ASSERT(isMarked()); 918 ASSERT(isMarked());
919 m_encoded &= ~headerMarkBitMask; 919 m_encoded &= ~headerMarkBitMask;
920 } 920 }
921 921
922 NO_SANITIZE_ADDRESS inline bool HeapObjectHeader::isDead() const { 922 NO_SANITIZE_ADDRESS inline bool HeapObjectHeader::isDead() const {
923 ASSERT(checkHeader()); 923 ASSERT(checkHeader());
924 return m_encoded & headerDeadBitMask; 924 return m_encoded & headerDeadBitMask;
925 } 925 }
926 926
927 NO_SANITIZE_ADDRESS inline void HeapObjectHeader::markDead() { 927 NO_SANITIZE_ADDRESS inline void HeapObjectHeader::markDead() {
928 // A Dead state should not happen in a per-thread heap world.
929 // TODO(haraken): Remove code to handle the Dead state.
930 CHECK(false);
928 ASSERT(checkHeader()); 931 ASSERT(checkHeader());
929 ASSERT(!isMarked()); 932 ASSERT(!isMarked());
930 m_encoded |= headerDeadBitMask; 933 m_encoded |= headerDeadBitMask;
931 } 934 }
932 935
933 inline Address NormalPageArena::allocateObject(size_t allocationSize, 936 inline Address NormalPageArena::allocateObject(size_t allocationSize,
934 size_t gcInfoIndex) { 937 size_t gcInfoIndex) {
935 if (LIKELY(allocationSize <= m_remainingAllocationSize)) { 938 if (LIKELY(allocationSize <= m_remainingAllocationSize)) {
936 Address headerAddress = m_currentAllocationPoint; 939 Address headerAddress = m_currentAllocationPoint;
937 m_currentAllocationPoint += allocationSize; 940 m_currentAllocationPoint += allocationSize;
(...skipping 10 matching lines...) Expand all
948 return outOfLineAllocate(allocationSize, gcInfoIndex); 951 return outOfLineAllocate(allocationSize, gcInfoIndex);
949 } 952 }
950 953
951 inline NormalPageArena* NormalPage::arenaForNormalPage() const { 954 inline NormalPageArena* NormalPage::arenaForNormalPage() const {
952 return static_cast<NormalPageArena*>(arena()); 955 return static_cast<NormalPageArena*>(arena());
953 } 956 }
954 957
955 } // namespace blink 958 } // namespace blink
956 959
957 #endif // HeapPage_h 960 #endif // HeapPage_h
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698