Page MenuHomePhabricator

Dynamic Backend Loading
Updated 1,774 Days AgoPublic

Version 2 of 51: You are viewing an older version of this document, as it appeared on Jun 10 2019, 3:24 PM.

Technical Contact: Matteo Martincigh

Pre-Implementation Review

Post-Implementation Review

Abstract

This is a design note to add to ability to dynamically load a backend in the ARmNN's runtime

VersionDateChangesAuthor
0.110/06/2016Initial draftMatteo Martincigh

Overview

Enable ArmNN to discover all the backends available on a system and dynamically load any it might find during the runtime's startup. It should be possible for the same compiled libarmnn.so deployed on different systems to load different backends. The same backend can be loaded simultaneously be different runtimes.

The current way of statically adding a backend at compile time must be retained.

Detailed Design

Main specifications:

  • Load the backends as shared libraries from a "backends" subdirectory in the path where libarmnn.so is
  • Use dlopen, dlclose and dlsym to load, unload and obtain the address of a symbol in the shared object respectively
  • All done in the Runtime constructor? Create a new "LoadBackends" method in the Runtime class. Or add to the IRunTime::Create factory method
  • To be loaded properly, a shared object must implement all the methods defined by the IBackendInternal interface (rename it to IBackend once and for all?)
  • The backends implementation must be thread-safe where necessary, as the same backend object can be loaded by multiple runtimes?
  • If any backend fails to load, the error must be reported but the runtime should ignore the failing backend and continue to the next one, if any
  • Provide detailed documentation for the users who want to create their own (dynamic) backend
Last Author
MatteoArm
Last Edited
Jun 10 2019, 3:24 PM

Event Timeline

MatteoArm created this document.Jun 10 2019, 3:17 PM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jun 10 2019, 3:24 PM
MatteoArm published a new version of this document.
MatteoArm edited the content of this document. (Show Details)Jun 10 2019, 4:34 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 10:46 AM
MatteoArm published a new version of this document.Jun 11 2019, 12:03 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 1:37 PM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 1:46 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 2:02 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 2:08 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 2:11 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 2:31 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 2:50 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 3:11 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 3:32 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 3:37 PM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 3:40 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 3:45 PM
MatteoArm edited the content of this document. (Show Details)Jun 11 2019, 3:53 PM
MatteoArm added a subscriber: MatteoArm.
MatteoArm edited the content of this document. (Show Details)Jun 12 2019, 10:10 AM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jun 13 2019, 3:54 PM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jun 14 2019, 11:02 AM
MatteoArm edited the content of this document. (Show Details)Jun 14 2019, 4:24 PM
MatteoArm edited the content of this document. (Show Details)Jun 26 2019, 8:01 AM
MatteoArm edited the content of this document. (Show Details)Jun 26 2019, 1:06 PM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jun 26 2019, 2:07 PM
MatteoArm edited the content of this document. (Show Details)Jun 26 2019, 2:27 PM
MatteoArm published a new version of this document.
MatteoArm edited the content of this document. (Show Details)Jun 26 2019, 2:52 PM
MatteoArm edited the content of this document. (Show Details)Jun 26 2019, 2:55 PM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jun 26 2019, 3:18 PM
MatteoArm edited the content of this document. (Show Details)Jun 27 2019, 7:58 AM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jul 3 2019, 1:54 PM
MatteoArm edited the content of this document. (Show Details)Jul 4 2019, 9:59 AM
MatteoArm edited the content of this document. (Show Details)Jul 4 2019, 10:30 AM
MatteoArm edited the content of this document. (Show Details)Jul 4 2019, 4:57 PM
MatteoArm edited the content of this document. (Show Details)Jul 5 2019, 3:40 PM
MatteoArm edited the content of this document. (Show Details)Jul 5 2019, 3:53 PM

I am happy to sign off on this document

MatteoArm changed the edit policy from "Custom Policy" to "Custom Policy".Jul 9 2019, 4:06 PM
MatthewARM edited the content of this document. (Show Details)Jul 11 2019, 3:07 PM
MatthewARM edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jul 11 2019, 3:31 PM
MatteoArm edited the content of this document. (Show Details)Jul 11 2019, 3:39 PM
brianjoycearm edited the content of this document. (Show Details)Jul 12 2019, 8:37 AM
MatteoArm edited the content of this document. (Show Details)Jul 22 2019, 12:06 PM
MatteoArm edited the content of this document. (Show Details)
MatteoArm edited the content of this document. (Show Details)Jul 22 2019, 12:59 PM
MatthewARM changed the visibility from "All Users" to "Public (No Login Required)".Jun 18 2020, 9:00 AM