Skip to content

Releases: vgvassilev/clad

Clad version 1.7

08 Aug 06:54
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.7. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.7?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-8 to clang-18

Forward Mode & Reverse Mode

  • Add propagators for __builtin_pow and __builtin_log
  • Support range-based for loops
  • Improve diagnostics clarity

Forward Mode

  • Advance support of frameworks such as Kokkos
  • Support std::array

Reverse Mode

  • Support non_differentiable attribute

Fixed Bugs

46 381 479 525 717 723 829 979 983 986 988 1005

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

A B (N)

petro.zarytskyi (11)
Vassil Vassilev (11)
Atell Krasnopolski (5)
Vaibhav Thakkar (2)
Mihail Mihov (2)
ovdiiuv (1)
Rohan Julka (1)
Max Andriychuk (1)

What's Changed

Full Changelog: v1.6...v1.7

Clad version 1.6

18 Jul 05:35
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.6. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.6?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-8 to clang-18

Forward Mode & Reverse Mode

  • Add support for simple lambda functions

Forward Mode

  • Support condition declarations and assignments
  • Enable logical operators in for loops
  • Support top level custom derivatives in vector mode
  • Add support for assignments in while-loops
  • Support for initializer_list
  • Support for const_cast
  • Add support for std::string variables

Reverse Mode

  • Improve consistency in the tape usage
  • Support pointer reference parameters
  • Remove redundant goto/label statements from the generated code

Misc

  • Improved CMake infrastructure via AddClad.cmake
  • Remove unnecessary clad::array_ref usages
  • Add support for computing only the diagonal hessian entries
  • Basic support for custom constructor pushforward functions

Fixed Bugs

273 352 509 789 874 899 908 911 913 922 927 951 965 972 974 978

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

A B (N)

Vaibhav Thakkar (16)
petro.zarytskyi (13)
Vassil Vassilev (13)
Atell Krasnopolski (11)
parth-07 (3)
dependabot[bot] (3)
Rohan Julka (2)
Jonas Rembser (2)
PetroZarytskyi (1)
Maxxxx (1)
Max Andriychuk (1)
Alexander Penev (1)

What's Changed

  • Bump requests from 2.31.0 to 2.32.0 by @dependabot in #901
  • Add support for null (empty) statements by @gojakuch in #900
  • Add a new cmake fn for using Clad with a library by @vaithak in #902
  • Add bugprone-argument-comment in clang-tidy by @vaithak in #910
  • Add check-clad-execonly target by @parth-07 in #875
  • Patch - Add cmake install of AddClad.cmake by @alexander-penev in #915
  • Make GlobalStoreAndRef consistent in usage inside and outside of loops by @PetroZarytskyi in #904
  • Fix clang tidy run failure in PR checks by @vaithak in #918
  • Fix condition declarations and assignments in for loops by @gojakuch in #905
  • Add support for the logical not operator in for-loop conds (forward mode) by @gojakuch in #920
  • Return type adjusted to depend on called function's return type by @ovdiiuv in #907
  • Improve derived variable init for const pointers by @vaithak in #919
  • Remove unnecessary usages of clad::array_ref and update the documentation by @PetroZarytskyi in #925
  • Print graph of diff requests in stats by @vaithak in #926
  • Revert removing clad::array_ref from InterfaceCompatibility.C by @PetroZarytskyi in #929
  • A reverse block is never ended in RMV::VisitConditionalStatement by @PetroZarytskyi in #928
  • Correctly handle pointer reference parameters in the reverse mode by @PetroZarytskyi in #906
  • Improve finding of higher order custom derivatives by @vaithak in #931
  • Fix an assertion when building the clad benchmarks with clang18 on osx. by @vgvassilev in #930
  • Simplify the Jacobian visitors. NFC by @vgvassilev in #924
  • Pass the DiffRequest down to the visitors. NFC. by @vgvassilev in #933
  • Emit clad::pop after clad::back when in RMV::VisitBinaryOperator by @PetroZarytskyi in #936
  • Remove useless goto/label statements by @PetroZarytskyi in #938
  • Add support for custom derivatives for top level derivatives by @vaithak in #934
  • Fix test failure on master due to rebasing by @vaithak in #942
  • Add links to the "Introduction to Clang for Clad contributors" doc by @gojakuch in #939
  • Add support for simple lambda expressions in forward mode by @gojakuch in #937
  • Remove the isVectorValued state from reverse mode visitor. NFC by @vgvassilev in #945
  • Add a link to the "Changing Everything With Clang Plugins" talk to the docs by @gojakuch in #949
  • Bump urllib3 from 2.0.7 to 2.2.2 by @dependabot in #948
  • Remove the use_enzyme state from reverse mode visitor. NFC by @vgvassilev in #946
  • Remove redundant data member in favor of centralizing in DiffRequest. NFC by @vgvassilev in #944
  • Remove the enableTBR state from reverse mode visitor. NFC by @vgvassilev in #947
  • Add support for assignments in while-loops by @ovdiiuv in #943
  • Take StorageClass from the canonical decl when cloning functions by @PetroZarytskyi in #953
  • Add validation to prevent error on empty if block by @rohanjulka19 in #952
  • [ci] Explicitly set CXX and CC as there is no default clang symlink on alpine. by @vgvassilev in #956
  • Add support for computing only the diagonal hessian entries by @vaithak in #950
  • Add support for && operator by @rohanjulka19 in #923
  • Don't synthesize 0 of the ArraySubscriptExpr type in forward mode by @PetroZarytskyi in #960
  • Add support for initializer_list in forward mode AD by @parth-07 in #935
  • Add support for const cast in fwd mode by @vaithak in #962
  • Add support for simple lambda expressions in reverse mode by @gojakuch in #955
  • Add primitive support for constructor custom pushforward functions by @parth-07 in #909
  • Fix the derivative of string literals in forward mode by @gojakuch in #967
  • Bump certifi from 2023.7.22 to 2024.7.4 by @dependabot in #969
  • Add shell.nix with an environment for building and using Clad on NixOS by @guitargeek in #973
  • Add support for std::string variables and functions with implicit constructor calls in their arguments by @gojakuch in #976
  • Fix pointer dereference in fwd mode by @vaithak in #975
  • Fix pointer arithmetic in fwd mode by @vaithak in #982

New Contributors

Full Changelog: v1.5...v1.6

Clad version 1.5

21 May 06:00
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.5. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.5?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-8 to clang-18

Forward Mode & Reverse Mode

  • Add support for C-style memory alloc and free

Reverse Mode

  • Replace array_ref with pointers in gradient signature
  • Initial support for new and delete operations in reverse mode

Error Estimation

  • Only track sizes of independent arrays
  • Remove .size() from error estimation
  • Simplify error estimation by removing _EERepl_ and _delta_

Misc

  • Teach binder to use the newest available version of clad
  • Simplify pullback calls by replacing _grad/_r pairs with single _r variables
  • Delay the differentiation process until the end of TU -- Clad now can operate just like clang and visit the entire translation unit to construct a precise differentiation plan
  • Remove extra lines generated when using clad::array or array_ref
  • Added timings report if -ftime-report flag is enabled

Fixed Bugs

248 350 704 715 765 769 790 792 798 805 854 865 867 886 887 890 897

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

A B (N)

petro.zarytskyi (30)
Vaibhav Thakkar (24)
Vassil Vassilev (21)
mcbarton (6)
Mihail Mihov (4)
dependabot[bot] (2)
Atell Krasnopolski (2)
Alexander Penev (2)
sauravUppoor (1)
kchristin22 (1)
Warren Jacinto (1)
Jonas Hahnfeld (1)
Deeptendu Santra (1)
Christina Koutsou (1)

What's Changed

New Contributors

**Full Changelo...

Read more

Clad version 1.4

29 Feb 15:55
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.4. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.4?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-7 to clang-17

Forward Mode & Reverse Mode

  • Improve handling of char and string literals

Reverse Mode

  • Add support for differentiating switch statements
  • Supportpassing pointers as call arguments
  • Fix pointer arithmetic for array types

Misc

  • Support BUILD_SHARED_LIBS=On

Fixed Bugs

300 313 636 735 748 753 774

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

A B (N)

Vassil Vassilev (9)
Vaibhav Thakkar (6)
maximusron (1)
bedupako12mas (1)
Parth (1)
Krishna Narayanan (1)
Aaron Jomy (1)

What's Changed

  • Fix for char and string literals as function args by @vaithak in #749
  • [cmake] Properly compute the path to gtest. by @vgvassilev in #754
  • [cmake] Move away from flat namespaces. by @vgvassilev in #755
  • Add support for differentiating switch stmt in the reverse mode AD. by @parth-07 in #339
  • [cmake] Clean up flags and treat warnings as errors in the ci. by @vgvassilev in #756
  • Fix passing pointers as call arguments by @vaithak in #763
  • Fix pointer arithmetic for array types by @vaithak in #764
  • [cmake] Make the compilation of gtest parallel by @vgvassilev in #770
  • [ci] Schedule the builds with debug clang earlier. by @vgvassilev in #771
  • [cmake] Support BUILD_SHARED_LIBS=On flags by @vgvassilev in #775
  • [cmake] Kokkos always requires rtti. by @vgvassilev in #776
  • Update InstallationAndUsage.rst by @bedupako12mas in #778
  • Remove implicit bool conversion check from clang-tidy by @vaithak in #784
  • [cmake] Only require git when running benchmarks. by @vgvassilev in #788
  • Update docs with dev build and higher order custom derivatives example by @maximusron in #787
  • Add support for 32bit CI build by @Krishna-13-cyber in #782
  • Add tests supporting higher order custom derivatives by @maximusron in #786

New Contributors

Full Changelog: v1.3...v1.4

Clad version 1.3

11 Feb 18:29
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.3. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.3?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-7 to clang-17

Forward Mode

  • Make forward vector mode more robust:
    • Implement dedicated clad::matrix class
    • Add support for array arguments
    • Add support for call expressions
  • Add support for the 'non_differentiable' attribute

Reverse Mode

  • Fix computation of higher order functions
  • Introduce experimental To-Be-Recorded Analysis in Clad
  • Improve storing of LHS/RHS in multiplication/division operators
  • Add initial support for pointers
  • Improve the overall performance by reducing the tape storage

Misc

  • Add support for std::min, std::max and std::clamp functions
  • Fix strong symbol definitions in Differentiator.h

Fixed Bugs

49 86 197 275 314 429 439 441 465 606 620 650 655 660 664 667 669 672 676 681 687 689

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

A B (N)

Vaibhav Thakkar (43)
Vassil Vassilev (26)
Alexander Penev (8)
petro.zarytskyi (6)
dependabot[bot] (4)
Parth (2)
Rishabh Bali (1)
QuillPusher (1)
Krishna-13-cyber (1)
daemondzh (1)
Aaron Jomy (1)

What's Changed

Read more

Clad version 1.2

18 Jul 15:12
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.2. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.2?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-5.0 to clang-16

Forward Mode

  • Add experimental support for forward vector mode.
  • Improve support of comma expressions.

Reverse Mode

  • Add pushforwards for std::floor and std::ceil.

Misc

  • Fill clad::array with 0s when assigned an empty brace-init list.
  • Improve documentation
  • Improve AD function interfaces with bitmasked options. For example:
    clad::differentiate<<clad::order::first, clad::opts::vector_mode>(f) will
    be equivalent to clad::differentiate<<1, clad::opts::vector_mode>(f) and
    will request the first order derivative of f in forward vector mode.

Fixed Bugs

218 395 521 523 541 566 573 582

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

Jonas Hahnfeld (27)
Vaibhav Thakkar (18)
Ris-Bali (5)
Garima Singh (3)
Vassil Vassilev (2)
Rishabh Bali (2)
vidushi (1)
petro.zarytskyi (1)
daemondzh (1)
ShounakDas101 (1)
Prajwal S N (1)
PetroZarytskyi (1)
Daemond (1)

Clad version 1.1

20 Jan 15:33
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.1. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.1?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-5.0 to clang-15

Forward Mode

  • Fix a bug in pow pushforward

Reverse Mode

  • Improve for-loop conditions

Error Estimation

  • Improvements in error estimation of arrays
  • Add error estimation example

Fixed Bugs

430 474 505 506 507 514 515

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

Alexander Penev (5)
Vassil Vassilev (3)
vidushi (2)
ioanaif (2)
Vaibhav Thakkar (1)
Parth Arora (1)
Garima Singh (1)
Baidyanath Kundu (1)

Clad version 1.0

07 Oct 00:02
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 1.0. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 1.0?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-5.0 to clang-14

Forward Mode & Reverse Mode

  • Add support for pushforward- and pullback-style functions which allow to accumulate the results from the AD when required to correctly compute derivatives when arguments are passed by reference or pointers

Forward Mode

  • Add support for member variables in functors
  • Add basic support for virtual functions
  • Add support for reference arguments
  • Add basic support for AD of class types wrt scalars
  • Add support for member functions, pointers, overloaded operators, pointer arithmetic, nullptr, sizeof and pseudo objects,

Reverse Mode

  • Add support for while and do-while statements
  • Add initial support for AD of user-defined types allowing to differentiate scalar types wrt user-defined types

CUDA

  • Add forward mode support for basic CUDA programs. More can be seen here

Error Estimation

  • Developed an error estimation framework to perform AD-based error estimation. The new facility is available via the clad::estimate_error interface. See more in this demo

Misc

  • Developed user documentation available at clad.readthedocs.io
  • Developed developers documentation available at doxygen
  • Implement a fallback to numerical differentiation if Clad cannot differentiate a given function. To disable this behavior, please compile your programs with the -DCLAD_NO_NUM_DIFF.
  • Add benchmarking infrastructure based on google benchmark
  • Add integration with Enzyme via clad::gradient<clad::opts::use_enzyme>(...)

Fixed Bugs

28 281 353 368 386 387 393 440

Special Kudos

This release wouldn't have happened without the efforts of our contributors, listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

Parth Arora (65)
Vassil Vassilev (49)
Garima Singh (17)
Baidyanath Kundu (13)
Nirhar (12)
Ioana Ifrim (9)
Alexander Penev (4)
RohitRathore1 (1)
David (1)

Clad version 0.9

15 Aug 18:23
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 0.9. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 0.9?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-5.0 to clang-13-rc1

Forward Mode & Reverse Mode

  • Add support for differentiating functor-like objects.
  • Preserve the type qualifiers in the derived function.
  • Develop initial support for differentiation of CUDA code.
  • Improve the doxygen-style documentation.

Forward Mode

  • Add support for differentiating while and do-while statements
  • Add switch statement differentiation support.
  • Add array differentiation support.
  • Allow the user to specify an array index as a independent variable. For instance, clad::differentiate(f, "p[1]");.

Reverse Mode

  • Extend the array differentiation support. See more in the demo.

Build System

  • Add cmake variables to control the locations where find_package discovers LLVM and Clang: LLVM_CONFIG_EXTRA_PATH_HINTS and Clang_CONFIG_EXTRA_PATH_HINTS respectively.

Fixed Bugs

  • Fix memory leaks in clad::Tape.
  • Fix bug in the clad::Tape::size().
  • Fix codegen Error for class function differentiation
    (139)

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

  • Baidyanath Kundu (21)
  • Parth Arora (21)
  • Vassil Vassilev (3)
  • Garima Singh (3)
  • axmat (1)
  • Ioana Ifrim (1)
  • Alexander Penev (1)

Clad version 0.8

28 May 15:52
Compare
Choose a tag to compare

Introduction

This document contains the release notes for the automatic differentiation plugin for clang Clad, release 0.8. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.

Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.

What's New in Clad 0.8?

Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.

External Dependencies

  • Clad now works with clang-5.0 to clang-12

Forward Mode & Reverse Mode

  • Implement #pragma clad ON/OFF/DEFAULT to control regions where clad is active
  • Support member functions with qualifiers in differentiation calls
  • Add getCode() interface for interactive use
  • Add support for using casts, * and & operators. For example:
    clad::differentiate(*&ptr_to_ptr, "...");

Misc

  • Add support for clang-11.1.0
  • Add support for clang-12

Fixed Bugs

  • Fixed several crashes in reverse mode.

Special Kudos

This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):

FirstName LastName (#commits)

  • Vassil Vassilev (14)
  • Baidyanath Kundu (10)
  • Garima Singh (7)
  • Alexander Penev (5)
  • Pratyush Das (3)
  • Parth Arora (2)
  • Ioana Ifrim (2)
  • Oksana Shadura (1)
  • Alex Efremov (1)