Skip to content

Expose LLVM instruction builder for neg and fneg#14774

Merged
straight-shoota merged 1 commit intocrystal-lang:masterfrom
JarnaChao09:feature/llvm-neg-api
Aug 7, 2024
Merged

Expose LLVM instruction builder for neg and fneg#14774
straight-shoota merged 1 commit intocrystal-lang:masterfrom
JarnaChao09:feature/llvm-neg-api

Conversation

@JarnaChao09
Copy link
Contributor

Purpose

Exposes the LLVM-C API to build neg and fneg instructions

Reason

While the neg instruction is just a "super instruction" to 0 - self, fneg as an instruction maintains NaN-ness inside of the floating point representation which may not be kept by performing 0 - self.

Notes

  • If requested, an issue can be opened under the general goal of exposing more/updating the LLVM-C API to its modern counterparts (e.g. LLVMArrayType vs LLVMArrayType2)
  • Bindings were tested as part of another project

@straight-shoota straight-shoota modified the milestones: 1.13.0, 1.14.0 Jul 3, 2024
@straight-shoota straight-shoota changed the title Exposing LLVM instruction builder API for the neg and fneg instructions Expose LLVM instruction builder for neg and fneg Aug 7, 2024
@straight-shoota straight-shoota merged commit ac2ecb0 into crystal-lang:master Aug 7, 2024
@JarnaChao09 JarnaChao09 deleted the feature/llvm-neg-api branch August 12, 2024 05:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants