Skip to content

Instantly share code, notes, and snippets.

@luizperes
Last active April 23, 2019 01:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save luizperes/2f4a3b49d08d52db7102c37a2084e8fe to your computer and use it in GitHub Desktop.
Save luizperes/2f4a3b49d08d52db7102c37a2084e8fe to your computer and use it in GitHub Desktop.
cmpt_415_notes.md
  • Jan 10th, 2019:
    • Got introduced to Parabix
    • Built LLVM and icgrep and got started with icgrep
    • Understood the basics of UTF-8 character encoding
  • Jan 12th, 2019:
    • Read some of the pages of CMPT 489 (https://coursys.sfu.ca/2018sp-cmpt-489-x1/pages/)
    • Got started with the basics of Pablo language
    • Understood the basics of the approach used by Parabix regarding bitwise data parallelism
    • Did small changes and created a new function simd_ternary on existing code (files idisa_builder.(h|cpp) and idisa_avx_builder.(h|cpp)).
  • Jan 16th, 2019:
    • Fixed bug where there was a missing return statement on the branch simd_ternary
    • Read and tried to understand Parabix code (character classes)
  • Jan 17th, 2019:
    • Asked questions and studied how to implement IDISA_Builder::simd_binary and IDISA_Builder::simd_ternary
    • Implemented IDISA_Builder::simd_binary and most of IDISA_Builder::simd_ternary
  • Jan 19th, 2019:
    • Fixed bugs and tested IDISA_Builder::simd_binary and IDISA_Builder::simd_ternary methods
    • Prepared and submitted merge request on GitLab
  • Jan 24th, 2019:
    • Debugged icgrep in order to understand its flow.
    • Read about character classes and got started with the model of creating bitwise operations with character ranges.
  • Jan 26th, 2019:
    • Studied the The Octet Group Technique that will be used on the ternary operations of Character classes.
    • Understood main aspects of its architecture so to modify and possibly refactor the code.
  • Jan 30th, 2019:
    • Refactored code in file cc_compiler.h and created the initial class Parabix_Ternary_CC_Compiler.
  • Jan 31st, 2019:
    • Implemented method that Parabix_Ternary_CC_Compiler::make_octets, according to the specification for octets
  • Feb 1st, 2019:
    • Fixed bugs in method Parabix_Ternary_CC_Compiler::make_octets
  • Feb 2nd, 2019:
    • Implemented method Parabix_Ternary_CC_Compiler::make_octets_expr that solves ranges for octets in a basis stream
    • Creating methods Or3 and And3
    • Implemented the reductions of terms in make_octets_expr method
    • Replaced all <Parabix_CC_Compiler> with <Parabix_Ternary_CC_Compiler> and had no much success
  • Feb 3rd, 2019:
    • Fixing a small bug related to bit shifting on octet function
  • Feb 7th, 2019:
    • Added printing option for ternary expressions
    • Added codegen for Ternary operators
  • Feb 9th, 2019:
    • Renamed octet_range_t to octet_pair_t and moved it to the cc_compiler.h file
    • Fixed some bugs related to the Parabix_Ternary_CC_Compiler
    • Added a small improvement for generating fewer expressions for ranges using the Parabix_Ternary_CC_Compiler
  • Feb 14th, 2019:
    • Created command line option for choosing the character class compiler
  • Feb 15th, 2019:
    • Fixed merging conflicts and little bugs
    • Adding checks for ternary expressions
  • Feb 16th, 2019:
    • Improved code for ternary expressions and removing unnecessary code
    • Optmized code by separating octets and ranges
    • Code cleaning
  • Feb 24th, 2019:
    • Prepared and implemented ternary instructions for UCD compiler
    • Added tests for ternary expressions
  • Feb 28th, 2019:
    • Made special methods for joining PabloAST Ors and Ands.
    • Optimizations on kernels (transforming binary instructions in ternary ones)
  • Mar 2nd, 2019:
    • Started to implement optimizations in the LLVM IR generated by the compiler
    • Fixed bugs in the idisa_avx_builder file
  • Mar 7th, 2019:
    • Adding functions for the simd simplifier (mk_simd_or, mk_simd_xor, mk_simd_and, mk_simd_not)
    • Created LLVM peephole pass.
  • Mar 9th, 2019:
    • Started new octet range expressions
  • Mar 16th, 2019:
    • Improved bit pattern expression for ternary instructions
    • Implemented octet range expressions (with some bugs)
    • Started the implementation for pivot expressions
  • Mar 21st, 2019:
    • Fixed bugs on branch make-ternary-ranges, the ones related to octet range expressions
  • Mar 23rd, 2019:
    • Implementing optimizations for ternary ranges with special cases:
      • hi + 1 = lo
      • hi with pattern xx111xx
      • lo with pattern xx000xx
      • ignore trailing zeroes on the lo value of the range
      • ignore trailing ones on the hi value of the range
  • Apr 31st, 2019:
    • Discussed with Nigel way of optimizing the final PabloAST using cc_compiler and pablo_simplifier
    • Implemented initial optimizations for ternary ranges
  • Apr 6th, 2019:
    • Created new helper functions for ternary operations such as createAndOr -> And(a, Or(b, c)), createOrAnd -> Or(a, And(b, c)), createXorAnd -> Xor(a, And(b, c)) and etc...
    • Cleaned bixnum.cpp and moved helper functions to PabloBuilder and PabloBlock classes
    • Created ternary mode optimization flag -EnableTernaryOpt
    • Broke triviallyFold function in many simpler functions such as triviallyFoldNot, triviallyFoldOr, triviallyFoldAnd and etc...
  • Apr 8th, 2019:
    • Started to implement write the code for ternary optimizations on pablo_simplifier pass
  • Apr 9th, 2019:
    • Final touches on ternary optimization implementation on pablo_simplifier pass
  • Apr 15th, 2019:
    • Started to write report and found bug on new gb18030 executable
  • Apr 18th, 2019:
    • Fixed a bug where the octet expressions was off by one when the basis streams count was equal 7
  • Apr 19th, 2019:
    • Fixed a bug on bitCast for AVX2
    • Continued writing report
  • Apr 20th, 2019:
    • Writing report
  • Apr 22nd, 2019:
    • Finished report
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment