biometrics / likely

A compiler intermediate representation for image recognition and heterogeneous computing.
http://www.liblikely.org
Other
78 stars 11 forks source link

Conditionals #29

Closed jklontz closed 10 years ago

jklontz commented 10 years ago

Support ternary (?:) conditionals

jklontz commented 10 years ago

@JordanCheney Perhaps you'd like to take this on after thresholding?

I think this is can happen in a few stages:

1) Comparisons: lt(lhs,rhs). lt = less than. also add functions for gt, lte, gte 2) Conditionals: if(condition,then,else). this would basically be a generalization of the current thresholding functionality.

jklontz commented 10 years ago

Oh and eq and neq

JordanCheney commented 10 years ago

Do conditionals still need to be implemented? Just want to make sure no one else completed this while I was on my hiatus :)

jklontz commented 10 years ago

Yeah, what I'm looking for is a translation of the LLVM select instruction as a Likely intrinsic, then implement threshold in terms of comparison and select

jklontz commented 10 years ago

Finished in 46b57832b9d4f3d05e49be77f011116445573364