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

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

Issue 14012005: Implement rethrow statement (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | runtime/vm/intermediate_language.h » ('j') | 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 "vm/flow_graph_builder.h" 5 #include "vm/flow_graph_builder.h"
6 6
7 #include "lib/invocation_mirror.h" 7 #include "lib/invocation_mirror.h"
8 #include "vm/ast_printer.h" 8 #include "vm/ast_printer.h"
9 #include "vm/code_descriptors.h" 9 #include "vm/code_descriptors.h"
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 1998 matching lines...) Expand 10 before | Expand all | Expand 10 after
2009 } 2009 }
2010 2010
2011 2011
2012 // List of recognized list factories in core lib: 2012 // List of recognized list factories in core lib:
2013 // (factory-name-symbol, result-cid, fingerprint). 2013 // (factory-name-symbol, result-cid, fingerprint).
2014 // TODO(srdjan): Store the values in the snapshot instead. 2014 // TODO(srdjan): Store the values in the snapshot instead.
2015 // TODO(srdjan): Add Float32x4List. 2015 // TODO(srdjan): Add Float32x4List.
2016 #define RECOGNIZED_LIST_FACTORY_LIST(V) \ 2016 #define RECOGNIZED_LIST_FACTORY_LIST(V) \
2017 V(ObjectArrayFactory, kArrayCid, 97987288) \ 2017 V(ObjectArrayFactory, kArrayCid, 97987288) \
2018 V(GrowableObjectArrayWithData, kGrowableObjectArrayCid, 816132033) \ 2018 V(GrowableObjectArrayWithData, kGrowableObjectArrayCid, 816132033) \
2019 V(GrowableObjectArrayFactory, kGrowableObjectArrayCid, 224791427) \ 2019 V(GrowableObjectArrayFactory, kGrowableObjectArrayCid, 369608996) \
2020 V(Int8ListFactory, kTypedDataInt8ArrayCid, 1178498933) \ 2020 V(Int8ListFactory, kTypedDataInt8ArrayCid, 2066002614) \
2021 V(Uint8ListFactory, kTypedDataUint8ArrayCid, 996047641) \ 2021 V(Uint8ListFactory, kTypedDataUint8ArrayCid, 1883551322) \
2022 V(Uint8ClampedListFactory, kTypedDataUint8ClampedArrayCid, 1504313643) \ 2022 V(Uint8ClampedListFactory, kTypedDataUint8ClampedArrayCid, 244333676) \
2023 V(Int16ListFactory, kTypedDataInt16ArrayCid, 1595869856) \ 2023 V(Int16ListFactory, kTypedDataInt16ArrayCid, 335889889) \
2024 V(Uint16ListFactory, kTypedDataUint16ArrayCid, 665298027) \ 2024 V(Uint16ListFactory, kTypedDataUint16ArrayCid, 1552801708) \
2025 V(Int32ListFactory, kTypedDataInt32ArrayCid, 728173538) \ 2025 V(Int32ListFactory, kTypedDataInt32ArrayCid, 1615677219) \
2026 V(Uint32ListFactory, kTypedDataUint32ArrayCid, 352036624) \ 2026 V(Uint32ListFactory, kTypedDataUint32ArrayCid, 1239540305) \
2027 V(Int64ListFactory, kTypedDataInt64ArrayCid, 105935265) \ 2027 V(Int64ListFactory, kTypedDataInt64ArrayCid, 993438946) \
2028 V(Uint64ListFactory, kTypedDataUint64ArrayCid, 943403644) \ 2028 V(Uint64ListFactory, kTypedDataUint64ArrayCid, 1830907325) \
2029 V(Float64ListFactory, kTypedDataFloat64ArrayCid, 348533743) \ 2029 V(Float64ListFactory, kTypedDataFloat64ArrayCid, 1236037424) \
2030 V(Float32ListFactory, kTypedDataFloat32ArrayCid, 1830794379) \ 2030 V(Float32ListFactory, kTypedDataFloat32ArrayCid, 570814412) \
2031 2031
2032 2032
2033 // Class that recognizes factories and returns corresponding result cid. 2033 // Class that recognizes factories and returns corresponding result cid.
2034 class FactoryRecognizer : public AllStatic { 2034 class FactoryRecognizer : public AllStatic {
2035 public: 2035 public:
2036 // Return kDynamicCid if factory is not recognized. 2036 // Return kDynamicCid if factory is not recognized.
2037 static intptr_t ResultCid(const Function& factory) { 2037 static intptr_t ResultCid(const Function& factory) {
2038 ASSERT(factory.IsFactory()); 2038 ASSERT(factory.IsFactory());
2039 const Class& function_class = Class::Handle(factory.Owner()); 2039 const Class& function_class = Class::Handle(factory.Owner());
2040 const Library& lib = Library::Handle(function_class.library()); 2040 const Library& lib = Library::Handle(function_class.library());
(...skipping 1303 matching lines...) Expand 10 before | Expand all | Expand 10 after
3344 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1; 3344 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1;
3345 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); 3345 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len);
3346 OS::SNPrint(chars, len, kFormat, function_name, reason); 3346 OS::SNPrint(chars, len, kFormat, function_name, reason);
3347 const Error& error = Error::Handle( 3347 const Error& error = Error::Handle(
3348 LanguageError::New(String::Handle(String::New(chars)))); 3348 LanguageError::New(String::Handle(String::New(chars))));
3349 Isolate::Current()->long_jump_base()->Jump(1, error); 3349 Isolate::Current()->long_jump_base()->Jump(1, error);
3350 } 3350 }
3351 3351
3352 3352
3353 } // namespace dart 3353 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/intermediate_language.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698