Flutter Engine
The Flutter Engine
third_party
dart-lang
sdk
runtime
vm
compiler
backend
dart_calling_conventions.h
Go to the documentation of this file.
1
// Copyright (c) 2024, the Dart project authors. Please see the AUTHORS file
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.
4
5
#ifndef RUNTIME_VM_COMPILER_BACKEND_DART_CALLING_CONVENTIONS_H_
6
#define RUNTIME_VM_COMPILER_BACKEND_DART_CALLING_CONVENTIONS_H_
7
8
#if defined(DART_PRECOMPILED_RUNTIME)
9
#error "AOT runtime should not use compiler sources (including header files)"
10
#endif
// defined(DART_PRECOMPILED_RUNTIME)
11
12
#include <utility>
13
14
#include "
platform/globals.h
"
15
#include "
platform/growable_array.h
"
16
#include "
vm/compiler/backend/locations.h
"
17
18
namespace
dart
{
19
20
class
Function;
21
22
namespace
compiler
{
23
24
// Array which for every parameter (or argument) contains its expected
25
// |Location| and its |Representation|.
26
using
ParameterInfoArray
=
GrowableArray<std::pair<Location, Representation>
>;
27
28
// For a call to the |target| function with |argc| arguments compute
29
// amount of stack space needed to pass all arguments in words.
30
//
31
// If |parameter_info| is not |nullptr| then it will be populated to
32
// describe expected location and representation of each argument.
33
//
34
// If |should_assign_stack_locations| is |false| then only arguments
35
// which will be passsed in registers have their locations computed.
36
// This does not affect return value: it is always equal to the
37
// number of words needed for all arguments which are passed on the stack.
38
intptr_t
ComputeCallingConvention
(
39
Zone
* zone,
40
const
Function
&
target
,
41
intptr_t argc,
42
std::function
<
Representation
(intptr_t)> argument_rep,
43
bool
should_assign_stack_locations,
44
ParameterInfoArray
* parameter_info);
45
46
}
// namespace compiler
47
48
}
// namespace dart
49
50
#endif
// RUNTIME_VM_COMPILER_BACKEND_DART_CALLING_CONVENTIONS_H_
dart::Function
Definition:
object.h:2990
dart::GrowableArray< std::pair< Location, Representation > >
dart::Zone
Definition:
unit_test_custom_zone.h:19
target
uint32_t * target
Definition:
fl_texture_registrar_test.cc:40
function
Dart_NativeFunction function
Definition:
fuchsia.cc:51
locations.h
compiler
Definition:
compiler.py:1
dart::compiler::ComputeCallingConvention
intptr_t ComputeCallingConvention(Zone *zone, const Function &target, intptr_t argc, std::function< Representation(intptr_t)> argument_rep, bool should_assign_stack_locations, ParameterInfoArray *parameter_info)
Definition:
dart_calling_conventions.cc:49
dart
Definition:
dart_vm.cc:33
dart::Representation
Representation
Definition:
locations.h:66
globals.h
growable_array.h
Generated on Sun Jun 23 2024 21:55:30 for Flutter Engine by
1.9.4