7d234ea1a108ccfa01082efc2309e658010554a3 |
|
31-Mar-2017 |
Yifan Hong <elsk@google.com> |
Add Formatter::join Test: pass Test: hidl_test Bug: 32559427 Change-Id: I44e27ba9b2e0fef605c340ba0f70f40ef0e6f390
/system/tools/hidl/Method.cpp
|
937408abc412733f46ba59e2342496b465e8c312 |
|
20-Mar-2017 |
Steven Moreland <smoreland@google.com> |
s/IMPL_HEADER/IMPL_INTERFACE/g More appropriate name for this enum constant now that they are defined in the interface source files. Test: hidl_test Change-Id: Ice531adb797c3213a2da18421b7e97fcfc888da3
/system/tools/hidl/Method.cpp
|
37065d636ffcb246da079837c1659dfab4d02438 |
|
07-Feb-2017 |
Andreas Huber <andih@google.com> |
Adds a debug(...) method to IBase, the base class for all Treble interfaces The default implementation does nothing but this allows implementations to emit diagnostics to a given file handle in a unified fashion. Bug: 33961528 Test: hidl_test, hidl_test_java Change-Id: Id7e8417275934c73032c9832c41e041d2d5d2fb7
/system/tools/hidl/Method.cpp
|
cd2ae45f51a5ad7089e2ec2fa922e2d4a0f7d136 |
|
31-Jan-2017 |
Yifan Hong <elsk@google.com> |
Add getReferenceInfo to IBase. Also added a IMPL_STUB_IMPL for HIDL reserved methods that: * add a method with the same name and signature to BnHwFoo * BnHwFoo::onTransact will call BnHwFoo::method instead of _hidl_mImpl->method * Content of IMPL_STUB_IMPL will go to BnHwFoo::method. Test: make and tested NFC / light / audio Test: hidl_test Change-Id: I85f6314450178c02c7bcba91c8a9fffbce822c76
/system/tools/hidl/Method.cpp
|
ffa913993fb527b44053c11f139689d3267748ec |
|
31-Jan-2017 |
Yifan Hong <elsk@google.com> |
Get method signatures from IBase.hal instead of hardcoding them in hidl-gen. Test: hidl_test Bug: 32559427 Change-Id: Ib0d3beca695fca47eb5f82d5d54c651da9af3687
/system/tools/hidl/Method.cpp
|
8d12b50cfb20eaef50e0998abe8d458866896003 |
|
27-Dec-2016 |
Martijn Coenen <maco@google.com> |
Support (un)linkToDeath in Java. Test: mma, hidl_test_java Bug: 31632518 Change-Id: Ic324deb5b0b17340328a08e736e07b47a7bea59b
/system/tools/hidl/Method.cpp
|
115d428f9c38c078d679a98942c47ce4a17bd599 |
|
19-Dec-2016 |
Martijn Coenen <maco@google.com> |
Add (un)linkToDeath to generated interfaces. (un)linkToDeath is now a part of IBase, and can be called on any generated HIDL interface. The implementation is a no-op, except in proxy objects, which are by definition a different process than the interface they point to. Since clients are not aware of the transport implementation, we must wrap the transport-independent callback in a transport-specific callback object. In case of binder, that object is a hidl_binder_death_recipient. The binder proxy object contains a list of registered death recipients, as well as a mutex to protect access to the list. The list is required to allow us to map back transport-independent callbacks to transport-dependent callbacks in unlinkToDeath(). Bug: 31632518 Test: mma, hidl_test Change-Id: I5083a8789dd706a886a8a09f8c733031a351a36a
/system/tools/hidl/Method.cpp
|
7763ab3046cb998ac8a32b8d2312981631886813 |
|
14-Dec-2016 |
Yifan Hong <elsk@google.com> |
Disallow duplicated argument name or result name. Test: compiles Test: hidl-gen -Lc++ -r tests:system/tools/hidl/test \ -r android.hidl:system/libhidl/transport -o ~/temp \ tests.errors.syntax@1.0 Bug: 33277700 Change-Id: I67c0f8df1a23b1155664aa448d8422953a8a77c5
/system/tools/hidl/Method.cpp
|
9df5244c1dd4508cc2e25f8a04d363903912d19c |
|
12-Dec-2016 |
Steven Moreland <smoreland@google.com> |
Cleanup way elidable types are determined. After adding the pointer type, it didn't make sense for elidable types to be specified in canElideCallback. Now the decision as to whether a specific type is elidable has been moved into 'isElidableType' on the Type class. Bug: 33298401 Test: mma in hardware/interfaces Change-Id: I66cbaed4c533013a52e59fc8e7edcdabc9ab9f20
/system/tools/hidl/Method.cpp
|
99e6bebc96d75d1c9b9b8130cd9b880dacb95b01 |
|
01-Dec-2016 |
Martijn Coenen <maco@google.com> |
memory -> hidl_memory and pointer -> hidl_pointer Test: hidl_test Change-Id: Id71c742867be01e80cd48f689c0c619f6b647aac
/system/tools/hidl/Method.cpp
|
4ed1347cd29e6e07acad368891bb03078c798aba |
|
02-Nov-2016 |
Yifan Hong <elsk@google.com> |
Remove extra from getJavaType. Bug: 32559427 Test: hidl_test_java Change-Id: I1a96630eed1b61ab4ff2959ced2e83f94e8fb36d
/system/tools/hidl/Method.cpp
|
3b320f8a60e4343bf06319bca3fc949c95eaf326 |
|
01-Nov-2016 |
Yifan Hong <elsk@google.com> |
Remove extra from getCppType. The argument is used for array type originally. We now use hidl_array instead of T[], so there is no need to use extra. Renamed the convenience getCppType to getCppStackType to avoid casting to (Type *) before using this method (which makes it inconvenient) Also fixes: * RefType::getCppType ignores specifyNamespaces * ConstantExpression.cpp emits a C-style cast instead of static_cast Bug: 32559427 Test: mma passes Test: hidl_test Change-Id: I7e2e31c34c1ca1aa83c4a5a4dbdf7fd6b9aff30c
/system/tools/hidl/Method.cpp
|
41c6d2e208df3762c6fabb2a7652296e5272059b |
|
07-Nov-2016 |
Steven Moreland <smoreland@google.com> |
Cleanup spaces in output. Remove newline between MQDescriptor and Status import in c++-impl and alphabetize them. Prevent functions from having multiple spaces before their opening bracket. Test: visually confirmed output Change-Id: I8054325682e6aa2d493398d4878838ec47bf0435
/system/tools/hidl/Method.cpp
|
10fe0b55e774903fe37b658458053527da8b5a53 |
|
19-Oct-2016 |
Yifan Hong <elsk@google.com> |
IHidlInterfaceBase for all autogenerated interfaces. Add an interfaceChain() method to each interface to facilitate casting between interfaces. Add ::descriptor for each interface (so that IFoo::descriptor won't fall back to IHidlInterfaceBase::descriptor. Test: hidl_test Test: cd system/tools/hidl && mma Test: cd hardware/interfaces/test && mma Bug: 32337854 Change-Id: I317b7905750db0bfefc4c5fd608a07080923c719
/system/tools/hidl/Method.cpp
|
ef1a9feda3f09f87f0673cc978b36e1d4a8b4223 |
|
07-Oct-2016 |
Steven Moreland <smoreland@google.com> |
Get rid of call enum. Bug: 31758541 Test: hidl_test, hardware/interfaces mma, manual inspection of output files Change-Id: I16c076dbff9b0b8688e2492b0b9c97e9f6d48943
/system/tools/hidl/Method.cpp
|
4c865b72b320a46f326a335cfd326b66b0e10f67 |
|
15-Sep-2016 |
Andreas Huber <andih@google.com> |
[Java hidl-gen] Fix multi-dimensional arrays (used within structures, not as method arguments). Bug: 31438033 Change-Id: I8e29ae8eca2a9ef8a320e37ca0bb79dcfa8a9b9a
/system/tools/hidl/Method.cpp
|
d537ab02e1707597d70665fd8c75ca1ec9f57326 |
|
12-Sep-2016 |
Steven Moreland <smoreland@google.com> |
Remove dependency on libutils. As part of this, TypeDef has also been converted to a NamedType. This is because originally, Scope contained just a KeyedVector<localname, idx> of types which it contained, and an std::vector<type> which idx indexes into (KeyedVector<localname, type> alone would have also worked). However, now it contains a std::map<localname, idx> instead. Because of this, we have lost the ability to iterate over the keys (localnames) in O(n). By converting TypeDef to a NamedType, name => idx => type such that name == type->name. This also means that in function hierarchy calling Scope::addType, we no longer have to pass around the tuple (name, type) since type->name == name, and we can pass around only type. Change-Id: I8f85afe0e389979a2fd98ff5eeccf47e3fcc8307
/system/tools/hidl/Method.cpp
|
a72e0d2be173cebf62f728b9d215808bd862f219 |
|
09-Sep-2016 |
Iliyan Malchev <malchev@google.com> |
Revert "Revert "Split out libhidl-gen and libhidl-gen-utils."" Shared code between hidl-gen, c2hal, and VTS. Also build for device, as we might use libhidl-gen reflectively in future (for profiling and instrumentation). Change-Id: Ia56901f4afbc12b7c2abee693e0ebea97ba76a8b
/system/tools/hidl/Method.cpp
|
194c2ffccef2dd1c515397e597f26b184bc1269b |
|
10-Sep-2016 |
Steven Moreland <smoreland@google.com> |
Revert "split out libhidl-gen and libhidl-gen-utils" This reverts commit 1316091aaf89abc73ab11539b61b20f13ee261c4. Change-Id: I97acad6cadd847cb5540ffe0258b081d7901c1e9
/system/tools/hidl/Method.cpp
|
941aea1c4ea511a72492a68e364f6a9d01366e55 |
|
09-Sep-2016 |
Steven Moreland <smoreland@google.com> |
Updated Method::generateCppSignature to respect namespaces. Passed on specifyNamespaces to respect namespaces within Return< ... >. Change-Id: Ic50e1bebe6aa11b65db848e1ac00079582cdee09
/system/tools/hidl/Method.cpp
|
1316091aaf89abc73ab11539b61b20f13ee261c4 |
|
09-Sep-2016 |
Iliyan Malchev <malchev@google.com> |
split out libhidl-gen and libhidl-gen-utils Shared code between hidl-gen, c2hal, and VTS. Also build for device, as we might use libhidl-gen reflectively in future (for profiling and instrumentation). Change-Id: Iffdcbf99308e1f69a504e89fcbb4c9447a6bbe7e Signed-off-by: Iliyan Malchev <malchev@google.com>
/system/tools/hidl/Method.cpp
|
7f949cb428ffd7a9370815ca5e32061e174e1479 |
|
09-Sep-2016 |
Iliyan Malchev <malchev@google.com> |
Method: minor cleanup Change-Id: Ib371f5e0c7f2a7aa7246270052f9d8c7d4630479
/system/tools/hidl/Method.cpp
|
979e099f1163ff75beed5776cd01fb409b90a0cd |
|
07-Sep-2016 |
Steven Moreland <smoreland@google.com> |
Added knowledge of namespacing into generation. This is the first step in making code aware of namespacing. Currently, the solution to generate symbols which are properly namespaced is to post-process text after it is being outputed by a Formatter. Ideally objects will know what namespace they are in and be able to print themselves out accordingly. This change specifically will allow generated code to remove namespaces from symbols that don't need to be qualified entirely without relying on post-processing to remove the namespace. Change-Id: Ie535d05a64eb3d6c7d3b5451abdaa289c574170f
/system/tools/hidl/Method.cpp
|
d57066f167eab04f32c8ef7e644e2a036256209b |
|
08-Sep-2016 |
Iliyan Malchev <malchev@google.com> |
hidl-gen: use Return<void> C++ HIDL methods now return Return<> objects regadless of elision status. This hides Status from auto-generated code. b/31367910 b/31348667 b/31365311 Change-Id: Ib009d2bade022a557f51d3cd4cb3e61ece38bba2 Signed-off-by: Iliyan Malchev <malchev@google.com>
/system/tools/hidl/Method.cpp
|
a7a421a87c3721d3efa9b611cd5cd76cd566606b |
|
07-Sep-2016 |
Steven Moreland <smoreland@google.com> |
Generalized cpp method generation. Change-Id: Ia91d03eaadae79eb5508e3fc57817bcf1cf9f1aa
/system/tools/hidl/Method.cpp
|
1aec397b1fdea7db4120dbe55b6995bb2a9d9138 |
|
26-Aug-2016 |
Andreas Huber <andih@google.com> |
Adds (C)opyright headers everywhere. Change-Id: I453af702f80aa4159ef6c3d29d9514b4897adc0a
/system/tools/hidl/Method.cpp
|
40d474a15ea87fb80b7344fba7602fbb2da2a449 |
|
16-Aug-2016 |
Iliyan Malchev <malchev@google.com> |
hidl-gen: callback elision for scalar returns Suppose a HIDL method has a generates clause with a single scalar (including an enum), for example as follows: add(uint32_t a, uint32_t b) generates(uint32_t sum); In this case, hidl-gen will emit the following method signature: SimpleReturn<uint32_t> add(uint32_t a, uint32_t b); SimpleReturn is a standard HIDL struct implementing a tuple of the return value (in this case, uint32_t) and a HWBinder Status object. The tuple can be used as a uint32_t, ignoring the Status value inside it, or the status value can be extracted from it: uint32_t tmol = ifc->add(41, 1); or: if (ifc->add(41, 1)) { ... or auto ret = ifc->add(41, 1); if (ret.status.isOk()) { ... With this, these methods that return a single scalar value do not have to use the awkward synchronous-callback syntax. b/30518487 Optimize out lamdas from HIDL C++ auto-generated code in common cases Change-Id: I83312e0b49d084c641c007df4a09e04a326b5245 Signed-off-by: Iliyan Malchev <malchev@google.com>
/system/tools/hidl/Method.cpp
|
70a59e1dc3dcf32f791d2dd7966111d4adf32eca |
|
16-Aug-2016 |
Andreas Huber <andih@google.com> |
Validate upfront that an interface is compatible with our Java backend, emit diagnostics if it is not. Also cleans up all other error messages to clearly indicate an error condition. Bug: 30876839 Change-Id: I18bcd723107ab93abcad38c976f3c38dda60a743
/system/tools/hidl/Method.cpp
|
639bff877ed39a7605dab30055f7322b9c3df962 |
|
13-Aug-2016 |
Iliyan Malchev <malchev@google.com> |
hidl-gen: accept oneway methods b/30843534: oneway methods seem broken Change-Id: I122fc26b4054eb0952d209e6b8c18d3a2ea446df Signed-off-by: Iliyan Malchev <malchev@google.com>
/system/tools/hidl/Method.cpp
|
5158db484e5ab302368f191d75d5b1334c270e52 |
|
10-Aug-2016 |
Zhuoyao Zhang <zhuoyao@google.com> |
Extend hidl-gen to support generate vts file. b/30762234 TODO: add regression test. Change-Id: I1c31fd9a85805cd450ea03cc0ccc750a756d1009
/system/tools/hidl/Method.cpp
|
2831d5145675ead9f2fb767bf5fe4ae56b88349f |
|
15-Aug-2016 |
Andreas Huber <andih@google.com> |
Initial commit of Java backend to hidl-gen. Change-Id: I38b62637df74d3e5daf702a8996502d0d5726033
/system/tools/hidl/Method.cpp
|
3599d928cbed73ba3e3872c095c2d1f65796c733 |
|
09-Aug-2016 |
Andreas Huber <andih@google.com> |
Interface methods can now be annotated. The syntax is a strict subset of what Java supports. The following are valid annotations: @Fragile @LotsOfStuff(single="yes", many={"a", "b", "c"}) An annotation either has no parameters (in which case the name is NOT followed by parentheses) or is does and what follows the name is a parenthesized list of name=value pairs, where each value is either a single quoted string literal or a list of quoted string literals surrounded by curly braces. Change-Id: I3c51d771b7d55c8d16531286d011f61be700a21c
/system/tools/hidl/Method.cpp
|
31629bcd51ab30bc0aadc69f3fc8ce4893eca900 |
|
03-Aug-2016 |
Andreas Huber <andih@google.com> |
Saner determination of a declared type's name (now short + full name) at the time the type is introduced to a scope.
/system/tools/hidl/Method.cpp
|
867fcb63af8c3ac96ed1b3f3950525aa70393bdf |
|
03-Aug-2016 |
Andreas Huber <andih@google.com> |
bye bye, dump(), RefType no longer gets a name.
/system/tools/hidl/Method.cpp
|
881227d860c59471eee31d39946e96ce2daa35d6 |
|
02-Aug-2016 |
Andreas Huber <andih@google.com> |
generate C++ interface header, proxy and stub headers and sources.
/system/tools/hidl/Method.cpp
|
c9410c7e62a33fd7599b2f3e025093a2d171577e |
|
28-Jul-2016 |
Andreas Huber <andih@google.com> |
initial commit of reimplementation of hidl-gen commit 56da787631c17276bc987f19649c6c1ea92200c3 Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 12:18:57 2016 -0700 ast.cpp => AST.cpp commit 095552aba072152d9c87475895cd2e97c43b7b03 Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 10:43:04 2016 -0700 TypeContainer => Scope, since it now also holds constants. commit 89ec1c511e7806037a53e43333c37fdf1b7aa39e Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 10:41:05 2016 -0700 initial support for constants commit b60b7ae588654b634bfdc5c283a25dd6378e1df7 Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 10:01:46 2016 -0700 Support for typedef, maintain ordering inside TypeContainer commit 8e83034a077ce2309deeb0e2094079cf6f11d8b4 Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 09:36:29 2016 -0700 support for optional super interface commit 9d44b022adb4a68dfca67ba2a6d845b7c8f27b88 Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 09:28:18 2016 -0700 ast => AST commit 48fd7f8a4e8ecf230cfc416aec6c8f6115e410af Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 09:26:44 2016 -0700 Each type in its own source/header file pair. commit ca1285ecbcbbb1340eec476e3fd4d1334908d8c1 Author: Andreas Huber <andih@google.com> Date: Thu Jul 28 08:52:24 2016 -0700 added scalar types "char", "bool" and "opaque" commit fbb351e5f4392fcbbce77402dfe059a1c8d79fb2 Author: Andreas Huber <andih@google.com> Date: Wed Jul 27 13:47:32 2016 -0700 some fixes to the parser and ast. commit 78288216b101349e9364c2d4470ecb5b9a942f5c Author: Andreas Huber <andih@google.com> Date: Wed Jul 27 12:34:21 2016 -0700 Formatter, AST::dump(), NamedType commit 4b8cc5d0a8ff5f70cb53e21b56138124259b8bcb Author: Andreas Huber <andih@google.com> Date: Wed Jul 27 11:45:10 2016 -0700 revamp of the parser, scoped type containers commit 0193fbfa5c7ac3ac1ce306dfb9c55d879f8c02b5 Author: Andreas Huber <andih@google.com> Date: Wed Jul 27 10:13:35 2016 -0700 store output in AST. commit 7f53022123978cc7c2a05b0c4aba7a4c5deea93b Author: Andreas Huber <andih@google.com> Date: Wed Jul 27 10:06:54 2016 -0700 reentrant lexer/parser commit 3d3e343d6cea2fb127b203071e8aff08a5715011 Author: Andreas Huber <andih@google.com> Date: Tue Jul 26 15:27:02 2016 -0700 better typename lookup, comments. commit 39f13ae860dbd9ffd163a5c99f150170525457ef Author: Andreas Huber <andih@google.com> Date: Tue Jul 26 14:29:33 2016 -0700 an actual AST. commit b1f3f1d94a8d1257426da35ace5bc2af04c433b6 Author: Andreas Huber <andih@google.com> Date: Tue Jul 26 12:51:34 2016 -0700 initial commit Change-Id: I44d1d928a5f3dcb908e264d53af09bbe25d8c464
/system/tools/hidl/Method.cpp
|