Back to Basics: Algebraic Data Typesthere are commonalities between std::any and the algebraic types. 18Quick motivationWhy use pair? (brief version) pair is used many places in the classic STL. using M = std::map; M myMap = {{1 Returned from some algorithms, like mismatch, equal_range, and uninitialized_move_n.Why use tuple? (brief version) Since the STL uses pair to simulate “returning multiple results,” you might imagine returning minmax_result { T min; T max; }; and I recommend you do the same in your code.Why use tuple? (brief version) tuple is used (arcanely) to forward sets of arguments to pair’s constructor. More on this 0 码力 | 73 页 | 267.05 KB | 6 月前3
Just-in-Time Compilation - J F Bastien - CppCon 2020are condemned to repeat it. Bartlett, J. 1992. Familiar Quotations (16th ed.) Aycock, J. 2003. A Brief History of Just-In-Time Bastien, JF. 2020. CppCon—Just-in-Time compilation Van Eerd, T. 2021. CppCon—SOLID is to expand our minds regarding what’s possible with compilers. Let’s look at our first paper…A Brief History of Just-in-Time Software systems have been using “just-in-time” compilation (JiT) techniques and present a classification scheme for such systems. — 2003 Let’s start with our first paper.A Brief History of Just-in-Time Software systems have been using “just-in-time” compilation (JiT) techniques0 码力 | 111 页 | 3.98 MB | 6 月前3
Applicative: The Forgotten Functional PatternBegin Not To Understand The mechanics of Applicative Applicative in C++ 22A VERY BRIEF SURVEY OF EXISTING A VERY BRIEF SURVEY OF EXISTING WORK WORK (Michał Dominiak, CppCon 2015) (David Sankel, C++Now (Just 1) <*> (Just 2) -- => Just 3 pure (+) <*> (Just 1) -- => Just (+1) 30A VERY BRIEF SURVEY OF EXISTING A VERY BRIEF SURVEY OF EXISTING C++ WORK C++ WORK P0650 (C++ Monadic Interface, Vicente J. Botet0 码力 | 141 页 | 11.33 MB | 6 月前3
Writing Python Bindings for C++ Libraries: Easy-to-use PerformanceLibrary’s core written in C, the ndarray type and various common operations on it are implemented in C Brief overview of NumPy In [7]: x = np.array([6, 7, 8]); print("{}, {}".format(type(x), x.dtype))Brief overview of NumPyLet’s design a n-dimensional array (brief) How would you design a library exposing an API to an n-dimensional 0 码力 | 118 页 | 2.18 MB | 6 月前3
Back To Basics Functionshave addresses (they must after all!) and that we can store functions in pointers. We'll take a brief aside to show you how modern C++ also gives us the convenient std::function. Functions need not always hopefully you think in terms of functions as building blocks that you can compose together ● Brief aside -- for advanced users -- yes, you can use a variadic template and evaluate this at compile-time hopefully you think in terms of functions as building blocks that you can compose together ● Brief aside -- for advanced users -- yes, you can use a variadic template and evaluate this at compile-time0 码力 | 123 页 | 7.26 MB | 6 月前3
Back to Basics: Concurrencycompeting for a resource I don’t know who these people are??Does our hardware support Concurrency? Brief Architecture History 27Moore’s Law (1/2) 28 ● Around 1965 Gordon Moore predicted the number of readability) ■ Accidentally putting a lock, (or excessive locking) is bad for performance 91(Brief Aside) static in C++11 (and beyond) ● static local variable are guaranteed by the C++11 standard Allow multiple threads to enter ■ Related ideas ● (C++20) std::latch ● (C++20) std::barrier 119Brief Notes on Parallelism Parallelism being the simultaneous execution of threads (often with less thought0 码力 | 141 页 | 6.02 MB | 6 月前3
Pipeline Architectures in C++: Overloaded Pipe Operator | and Its Monadic Operations(required): Title and brief overview of what the poster reports on. Title: Pipeline architectures in C++: overloaded pipe operator | std::expected and its monadic operations Brief overview: Functional0 码力 | 3 页 | 422.24 KB | 6 月前3
Can Data-Oriented-Design be Improved?1Can data-oriented-design be improved? Ollivier Roberge Collège Jean-de-Brébeuf 2A brief historic • 1960s • FORTRAN • Lisp • 1980s • OOP • Structured programming • Modules • 2000s • Template You could use it in your code starting from today • It doesn’t need to be all about templates 37A brief historic (again) • 1960s • FORTRAN • Lisp • 1980s • OOP • Structured programming • Modules •0 码力 | 39 页 | 1.18 MB | 6 月前3
Compile-Time Compression and Resource Generation with C++20this code Discuss some techniques I found building compile-time libraries 2 . 2/ constexpr in Brief Speci�es a variable or function CAN appear in a constant expression Constant expressions can be evaluated https://github.com/AshleyRoll/cpp_usbdescriptor https://www.beyondlogic.org/usbnutshell/usb1.sht This is a brief overview, check out the code for implementation details Most complex example - uses variadic templates0 码力 | 59 页 | 1.86 MB | 6 月前3
Back to Basics: Classic 9STLOverview of the STL 9CppCon 2021 – Back to Basics: Classic STL Copyright © 2021 Bob Steagall A Brief STL History • 1979, Alexander Stepanov begins exploring generic programming (GP) • 1988, Stepanov (2007) [emphasis mine] 12CppCon 2021 – Back to Basics: Classic STL Copyright © 2021 Bob Steagall A Brief STL History • 1979, Alexander Stepanov begins exploring generic programming (GP) • 1988, Stepanov0 码力 | 75 页 | 603.36 KB | 6 月前3
共 99 条
- 1
- 2
- 3
- 4
- 5
- 6
- 10
相关搜索词
BacktoBasicsAlgebraicDataTypesJustinTimeCompilationBastienCppCon2020ApplicativeTheForgottenFunctionalPatternWritingPythonBindingsforC++LibrariesEasyusePerformanceToFunctionsConcurrencyPipelineArchitecturesOverloadedPipeOperatorandItsMonadicOperationsCanOrientedDesignbeImprovedCompileCompressionResourceGenerationwith20Classic9STL













