summaryrefslogtreecommitdiff
path: root/boot/1.1/default/BootControl.cpp
diff options
context:
space:
mode:
authorDavid Gross <dgross@google.com>2019-10-01 11:59:34 -0700
committerLev Proleev <levp@google.com>2019-10-09 14:18:06 +0100
commit8c0a48bcebbb03188f04c53c1618aa60dcb6a706 (patch)
treeaf7f306a2a26643ec90ee5bf8e15cfda63052bb8 /boot/1.1/default/BootControl.cpp
parent9b2431d02a4af2117f3fde254ed130b0c0590718 (diff)
Replace sync_enums_to_hal.py with generate_api.{py,sh} and regenerate */types.hal
There are certain pieces of NeuralNetworks.h and of our various *.hal files that ought to be kept in sync -- most notably the operand type and operation type definitions and descriptions in our NeuralNetworks.h and types.hal files. To avoid having to do this manually, a tool can be employed. The old solution to this problem is sync_enums_to_hal.py, which parses the existing NeuralNetworks.h and types.hal files, and then rewrites the types.hal files: It identifies the operand type and operation type portions of the files, and in the types.hal files replaces them with transformed versions of the portions from NeuralNetworks.h. This approach is brittle -- it is very sensitive to the structure of the files, as was recognized when this tool was created. Changes to those files since the script was last updated essentially broke the script, as noted in http://b/140132458. The new solution employs a new tool generate_api.py to combine a single "specification file" with one "template file" per API file (NeuralNetworks.h or types.hal) to produce that API file. The script generate_api.sh invokes generate_api.py once per API file, passing appropriate arguments. See frameworks/ml/nn/tools/api/README.md for more details. In the process of combining information from NeuralNetworks.h and */types.hal, some formatting, syntactic, and semantic changes have been made to those files. For example: - types.hal files no longer refer to API levels or (similarly) to HAL versions other than earlier HAL versions Bug: 130169064 Bug: 140132458 Test: cd neuralnetworks ; mma Change-Id: Iceb38effc2c7e6c32344e49225b85256144c0945 Merged-In: Iceb38effc2c7e6c32344e49225b85256144c0945 (cherry picked from commit 2cae5c8b01605923044099dcf02ad4bb4566a5b4)
Diffstat (limited to 'boot/1.1/default/BootControl.cpp')
0 files changed, 0 insertions, 0 deletions