Files
sdk/pkg/native_compiler/lib/back_end/code.dart
T
Alexander Markov 3a9dbc9efa Initial code generation for instance field loads and stores
Also:
* Support receiving parameters on the stack.
* Computation of stack frame size.
* Mach-O symbols for functions and stubs.

Issue: https://github.com/dart-lang/sdk/issues/61635
Change-Id: Ic89ce5dbcad27c34d18790f2b526f1d33dfd6693
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/478161
Reviewed-by: Slava Egorov <vegorov@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2026-02-05 11:40:00 -08:00

25 lines
756 B
Dart

// Copyright (c) 2026, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
import 'dart:typed_data';
import 'package:cfg/ir/functions.dart';
import 'package:native_compiler/back_end/object_pool.dart';
/// Generated code for a function or a stub.
class Code {
final String name;
final CFunction? function;
final Uint8List instructions;
final ObjectPool objectPool;
/// Offset of instructions in the resulting image.
int? instructionsImageOffset;
Code(this.name, this.function, this.instructions, this.objectPool);
}
/// Comsumer of the generated code.
typedef CodeConsumer = void Function(Code);