Ticket #67 (accepted enhancement)

Opened 11 years ago

Last modified 5 years ago

FR: handle non-inlinable intrinsics (deals with MIN/MAX/RESHAPE...)

Reported by: Utke Owned by: utke
Priority: 3 Milestone:
Component: Miscellaneous Keywords:


some intrinsics have no easy closed form expression for the partials such as MIN/MAX. We also want to support user defined non-inlinable intrinsics.

Change History

Changed 10 years ago by Utke

Here is some previous e-mail conversation:

First, I don't believe we should allow just anything for the
partials. This would be too complex.
We want to cover
- simple partials that evaluate in a single expression,
- partials like the one for max that don't fit into an expression
- partials for user defined intrinsics
- partials for non-inlinable intrinsics (incl. user defined)
So the problem cases are the second and the fourth.
I would like a solution that covers both.
My current thinking for non-inlinable intrisics
foo(x,..,y,..) is that the non-inlinable intrinsics catalogues
specifies a foo_ad(x,...,y,..., partials,...)
I.e. the transformation replaces foo with foo_ad.
This maintains any potential efficiency advantage to be gained
by coupling the function and partials evaluation. (as opposed to
separating in function value and each partial)
In order for this to work we would need to provide a spot where
foo_ad is defined.
For the user defined things past discussions have gone towards
allowing a black box subroutine. 'foo_ad' would then just be the name
of the external routine to be found by the linker in some object file
that comes with the xaif file.
If we can do this then 'max' could be handled as a non-inlinable
intrinsic. So, in short, the handling of user defined non-inlinable intrinsics
with a black box partial providing subroutine requires quite a bit
of work on the xaifBooster side but it could avoid another special solution
for max, pow and the like.

There are of course other alternatives but now
I am in favor of this one. In 10 minutes it may change though.
Please let me know what you think


I guess that we need to make the definition of intrinsics more general allowing for pretty much everythiong that is in xaif to be used. We could then write sth. like

if (b<a) then

Changed 7 years ago by utke

  • status changed from Assigned to new

Changed 7 years ago by utke

  • status changed from new to closed
  • resolution set to fixed

done in the preprocessor now

Changed 6 years ago by utke

  • status changed from closed to reopened
  • resolution fixed deleted

Changed 6 years ago by utke

  • owner changed from Utke to utke
  • status changed from reopened to accepted

Changed 6 years ago by utke

additional changes done with:
============================ RegressionOpenAD
============================ SourceProcessing?
============================ xaifBooster
============================ xaif

Changed 6 years ago by utke

need to fix adm for transpose

Changed 5 years ago by utke

  • summary changed from FR: handle non-inlinable intrinsics (deals with MIN/MAX) to FR: handle non-inlinable intrinsics (deals with MIN/MAX/RESHAPE...)

Changed 5 years ago by utke

  • type changed from defect to enhancement
Note: See TracTickets for help on using tickets.