blob: de2c913f8e1a52e0aacbea6a25335556667f3827 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
using System;
using Internal.TypeSystem;
namespace ILCompiler.DependencyAnalysis.X86
{
/// <summary>
/// Maps logical registers to physical registers on a specified OS.
/// </summary>
public struct TargetRegisterMap
{
public readonly Register Arg0;
public readonly Register Arg1;
public readonly Register Result;
public TargetRegisterMap(TargetOS os)
{
switch (os)
{
case TargetOS.Windows:
case TargetOS.Linux:
Arg0 = Register.ECX;
Arg1 = Register.EDX;
Result = Register.EAX;
break;
default:
throw new NotImplementedException();
}
}
}
}
|