Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ordering of APIs. #3951

Merged
merged 1 commit into from
May 15, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions csharp/src/Microsoft.ML.OnnxRuntime/NativeMethods.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ public struct OrtApiBase
public IntPtr GetVersionString;
};

// NOTE: The order of the APIs in this struct should match exactly that in
// OrtApi ort_api_1_to_3 (onnxruntime_c_api.cc)
[StructLayout(LayoutKind.Sequential)]
public struct OrtApi
{
Expand All @@ -38,8 +40,8 @@ public struct OrtApi
public IntPtr EnableCpuMemArena;
public IntPtr DisableCpuMemArena;
public IntPtr SetSessionLogId;
public IntPtr SetSessionLogSeverityLevel;
public IntPtr SetSessionLogVerbosityLevel;
public IntPtr SetSessionLogSeverityLevel;
public IntPtr SetSessionGraphOptimizationLevel;
public IntPtr SetIntraOpNumThreads;
public IntPtr SetInterOpNumThreads;
Expand All @@ -59,8 +61,8 @@ public struct OrtApi
public IntPtr SessionGetOutputName;
public IntPtr SessionGetOverridableInitializerName;
public IntPtr CreateRunOptions;
public IntPtr RunOptionsSetRunLogSeverityLevel;
public IntPtr RunOptionsSetRunLogVerbosityLevel;
public IntPtr RunOptionsSetRunLogSeverityLevel;
public IntPtr RunOptionsSetRunTag;
public IntPtr RunOptionsGetRunLogVerbosityLevel;
public IntPtr RunOptionsGetRunLogSeverityLevel;
Expand Down