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

Issue 1294001: Make the seccomp sandbox compatible with tcmalloc:... (Closed)

Created:
10 years, 9 months ago by Markus (顧孟勤)
Modified:
7 years, 11 months ago
CC:
chromium-reviews
Visibility:
Public.

Description

Fix a few more places where we need to use our own allocator. Make tcmalloc compatible with the seccomp sandbox by avoiding making direct system calls from within tcmalloc. BUG=38973 TEST=none Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=42667

Patch Set 1 #

Total comments: 3

Patch Set 2 : '' #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+34 lines, -10 lines) Patch
M sandbox/linux/seccomp/library.h View 1 3 chunks +17 lines, -4 lines 0 comments Download
M sandbox/linux/seccomp/maps.h View 1 chunk +2 lines, -1 line 0 comments Download
M third_party/tcmalloc/chromium/src/base/spinlock_linux-inl.h View 1 4 chunks +15 lines, -5 lines 1 comment Download

Messages

Total messages: 10 (0 generated)
Evan Martin
LGTM (as always, I don't fully understand it)
10 years, 9 months ago (2010-03-24 19:25:36 UTC) #1
agl
LGTM http://codereview.chromium.org/1294001/diff/1/4 File sandbox/linux/seccomp/library.h (right): http://codereview.chromium.org/1294001/diff/1/4#newcode152 sandbox/linux/seccomp/library.h:152: typedef std::map<Elf_Addr, Range, GreaterThan, Any reason why this ...
10 years, 9 months ago (2010-03-24 19:31:59 UTC) #2
willchan no longer on Chromium
I'm going to update your changelist description to be a bit more exact if you ...
10 years, 9 months ago (2010-03-24 19:39:59 UTC) #3
willchan no longer on Chromium
http://codereview.chromium.org/1294001/diff/1/4 File sandbox/linux/seccomp/library.h (right): http://codereview.chromium.org/1294001/diff/1/4#newcode155 sandbox/linux/seccomp/library.h:155: typedef std::map<string, std::pair<int, Elf_Shdr>, std::less<string>, you need #include <functional> ...
10 years, 9 months ago (2010-03-24 19:42:15 UTC) #4
Markus (顧孟勤)
I added a brief comment. In short, it has to do with the fact that ...
10 years, 9 months ago (2010-03-25 20:17:53 UTC) #5
agl
On Thu, Mar 25, 2010 at 4:17 PM, <markus@chromium.org> wrote: >> LGTM LGTM still applies ...
10 years, 9 months ago (2010-03-25 20:18:53 UTC) #6
Markus (顧孟勤)
Sure. I don't mind you changing the change description. Technically, we are fixing a bug ...
10 years, 9 months ago (2010-03-25 20:19:31 UTC) #7
Markus (顧孟勤)
On 2010/03/24 19:42:15, willchan wrote: > http://codereview.chromium.org/1294001/diff/1/4 > File sandbox/linux/seccomp/library.h (right): > > http://codereview.chromium.org/1294001/diff/1/4#newcode155 > ...
10 years, 9 months ago (2010-03-25 20:19:59 UTC) #8
willchan no longer on Chromium
LGTM, thanks for the updates!
10 years, 9 months ago (2010-03-25 20:28:15 UTC) #9
Markus (顧孟勤)
7 years, 11 months ago (2013-01-25 22:24:00 UTC) #10
Message was sent while issue was closed.
https://codereview.chromium.org/1294001/diff/9001/third_party/tcmalloc/chromi...
File third_party/tcmalloc/chromium/src/base/spinlock_linux-inl.h (right):

https://codereview.chromium.org/1294001/diff/9001/third_party/tcmalloc/chromi...
third_party/tcmalloc/chromium/src/base/spinlock_linux-inl.h:90: nanosleep(&tm,
NULL);
I was researching some unrelated problem, and came across
http://stackoverflow.com/questions/7086220/what-does-rep-nop-mean-in-x86-asse...

It sounds as if our current code can wreak havoc with hyper-threading. We should
probably insert an:

  asm volatile("rep nop");

We might also need this instruction for the syscall(__NR_futex); not entirely
sure if it is needed there though. The system call might already do this.

We should probably run this past somebody who knows more about CPU
architectures? Maybe, m3b?

Powered by Google App Engine
This is Rietveld 408576698