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

Side by Side Diff: runtime/vm/thread_linux.cc

Issue 8495007: Bump stack size for pure Dart isolates. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 9 years, 1 month 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 | Annotate | Revision Log
« 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 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include <errno.h> 5 #include <errno.h>
6 #include <sys/time.h> 6 #include <sys/time.h>
7 7
8 #include "vm/thread.h" 8 #include "vm/thread.h"
9 9
10 #include "vm/assert.h" 10 #include "vm/assert.h"
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 75
76 76
77 Thread::Thread(ThreadStartFunction function, uword parameter) { 77 Thread::Thread(ThreadStartFunction function, uword parameter) {
78 pthread_attr_t attr; 78 pthread_attr_t attr;
79 int result = pthread_attr_init(&attr); 79 int result = pthread_attr_init(&attr);
80 VALIDATE_PTHREAD_RESULT(result); 80 VALIDATE_PTHREAD_RESULT(result);
81 81
82 result = pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED); 82 result = pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED);
83 VALIDATE_PTHREAD_RESULT(result); 83 VALIDATE_PTHREAD_RESULT(result);
84 84
85 result = pthread_attr_setstacksize(&attr, 32 * KB); 85 result = pthread_attr_setstacksize(&attr, 1024 * KB);
86 VALIDATE_PTHREAD_RESULT(result); 86 VALIDATE_PTHREAD_RESULT(result);
87 87
88 ThreadStartData* data = new ThreadStartData(function, parameter, this); 88 ThreadStartData* data = new ThreadStartData(function, parameter, this);
89 89
90 pthread_t tid; 90 pthread_t tid;
91 result = pthread_create(&tid, 91 result = pthread_create(&tid,
92 &attr, 92 &attr,
93 ThreadStart, 93 ThreadStart,
94 data); 94 data);
95 VALIDATE_PTHREAD_RESULT(result); 95 VALIDATE_PTHREAD_RESULT(result);
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 } 232 }
233 233
234 234
235 void Monitor::NotifyAll() { 235 void Monitor::NotifyAll() {
236 // TODO(iposva): Do we need to track lock owners? 236 // TODO(iposva): Do we need to track lock owners?
237 int result = pthread_cond_broadcast(data_.cond()); 237 int result = pthread_cond_broadcast(data_.cond());
238 VALIDATE_PTHREAD_RESULT(result); 238 VALIDATE_PTHREAD_RESULT(result);
239 } 239 }
240 240
241 } // namespace dart 241 } // namespace dart
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