aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2017-06-13Merge branch 'bjorn/asn1/fix-asn1rt-reference'Björn Gustavsson
* bjorn/asn1/fix-asn1rt-reference: Remove reference to removed module 'asn1rt'
2017-06-13Remove reference to removed module 'asn1rt'Björn Gustavsson
2017-06-13process_SUITE: Don't leave processes runningBjörn Gustavsson
2017-06-13trace_port_SUITE: Don't leave processes runningBjörn Gustavsson
2017-06-13tracer_SUITE: Don't leave processes runningBjörn Gustavsson
2017-06-13trace_nif_SUITE: Don't leave processes runningBjörn Gustavsson
2017-06-13trace_bif_SUITE: Don't leave processes runningBjörn Gustavsson
2017-06-13trace_SUITE: Don't leave processes runningBjörn Gustavsson
2017-06-13message_queue_data_SUITE: Don't leave processes runningBjörn Gustavsson
2017-06-13Add informational test case z_SUITE:leaked_processes/1Björn Gustavsson
Add z_SUITE:leaked_processes/1 to print the process information for all new processes created during execution of the emulator test suite. Test cases are not supposed leak processes, because that could disturb later test cases.
2017-06-13Merge branch 'hans/ssh/doc_clearify_timeouts/OTP-14216'Hans Nilsson
2017-06-13Merge branch 'hasse/stdlib/fun2ms_partial_eval/OTP-14454/ERIERL-29'Hans Bolinder
* hasse/stdlib/fun2ms_partial_eval/OTP-14454/ERIERL-29: stdlib: Evaluate expressions in fun2ms bodies
2017-06-13Capitulate on SCTP vs sparc-sun-solaris2.10Anders Svensson
Despite the efforts of commits 1df74351 and 111261d1 to salvage it, SCTP is just flakey on sparc-sun-solaris2.10. In addition to the woes of the loopback address, even connect on other addresses sporadically returns {error, eafnosupport}, so the initial check for a working SCTP (aka resistance) is futile. Revert both commits.
2017-06-12Remove obsolete traffic testcaseAnders Svensson
Outgoing requests no longer write to the request table, as of commit a4da06a5.
2017-06-12Fix dialyzer warningsAnders Svensson
diameter_sctp.erl:292: Record construction #transport{parent::pid(),mode::{'accept',atom() | pid() | port() | {atom(),atom()}},active::'false',recv::'true',os::0,packet::'true',message_cb::'undefined',send::'false'} violates the declared type of field message_cb::'false' | fun() | maybe_improper_list(fun() | maybe_improper_list(any(),[any()]) | {atom(),atom(),[any()]},[any()]) | {atom(),atom(),[any()]} diameter_sctp.erl:302: Record construction #transport{mode::{'accept',atom() | pid() | port() | {atom(),atom()}},active::'false',recv::'true',os::0,packet::'true',message_cb::'undefined',send::'false'} violates the declared type of field message_cb::'false' | fun() | maybe_improper_list(fun() | maybe_improper_list(any(),[any()]) | {atom(),atom(),[any()]},[any()]) | {atom(),atom(),[any()]}
2017-06-12Merge branch 'siri/cuddle-master'Siri Hansen
* siri/cuddle-master: Update sasl_report_SUITE to accept new size of sasl.log
2017-06-12busy_port_SUITE: Ensure that all created procesesses are killedBjörn Gustavsson
2017-06-12busy_port_SUITE: Eliminate warnings for unused variablesBjörn Gustavsson
2017-06-12busy_port_SUITE: Eliminate 'export_all'Björn Gustavsson
2017-06-12after_SUITE: Don't leave a process runningBjörn Gustavsson
2017-06-12Remove minor diameter_config bloatAnders Svensson
Folded when I should have mapped.
2017-06-12Fix maximum AVP arity checkAnders Svensson
2017-06-12Use avp_arity/1 when creating a zero groupAnders Svensson
Converting with list_to_binary/1 appears to be faster than the equivalent binary comprehension: << (z(F,A)) || {F,A} <- avp_arity(Name) >>
2017-06-12Use avp_arity/1 when detecting missing AVPsAnders Svensson
Recursing over the entire list of arities and values is faster than retrieving them one at a time.
2017-06-12Add dictionary function avp_arity/1Anders Svensson
2017-06-12Don't prepend bit for sub binary optimizationAnders Svensson
2017-06-12Remove upgrade-related codeAnders Svensson
This and subsequent commits are destined for OTP 20.0.
2017-06-12Simplify value setting at decodeAnders Svensson
2017-06-12Simplify AVP decode as mapfoldlAnders Svensson
2017-06-12Be more flexible in what can be packed as 'AVP'Anders Svensson
In particular, allow {Name, Value} and {Dict, Name, Value} without requiring a diameter_avp wrapper.
2017-06-12Remove unnecessary value mappingAnders Svensson
Since value is ignored.
2017-06-12Use dictionary '#new-'/1 when creating CEAAnders Svensson
Which is the equivalent of what was done with '#new-'/1 and '#set-'/2.
2017-06-12Optimize sub binary creationAnders Svensson
2017-06-12Optimize sub binary creationAnders Svensson
base/diameter_codec.erl:716: Warning: OPTIMIZED: creation of sub binary delayed
2017-06-12Optimize sub binary creationAnders Svensson
base/diameter_codec.erl:545: Warning: OPTIMIZED: creation of sub binary delayed
2017-06-12Optimize sub binary creationAnders Svensson
base/diameter_codec.erl:600: Warning: OPTIMIZED: creation of sub binary delayed
2017-06-12Don't match for no useful reasonAnders Svensson
2017-06-12Avoid modifying records during encodeAnders Svensson
2017-06-12Don't create intermediate terms unnecessarily during encodeAnders Svensson
2017-06-12Don't create intermediate binaries unnecessarily during encodeAnders Svensson
Dict:avp(encode, Value, Name) no longer needs to return a binary, only an iolist(). Message encode runs list_to_binary/1 to convert accumulated lists into a message binary.
2017-06-12Fix encode of Grouped AVP as {Dict, Name, Data}Anders Svensson
This is a special case to allow encode of something other than an iolist. Eg. #diameter_avp{data = {diameter_gen_base_rfc6733, 'Proxy-Info', [{'Proxy-Host', "HOST"}, {'Proxy-State', "STATE"}]}} Only worked as expected for AVPs of type other than Grouped.
2017-06-12Remove minor encode bloatAnders Svensson
As when detecting missing AVPs, extract a list of field/value pairs in one step, which looks to be slightly more efficient. Flattening the list was unnecessary since the result is passed to list_to_binary.
2017-06-12Make encoding of Diameter header more efficientAnders Svensson
On the same theme as the parent commit, building binaries in fewer steps.
2017-06-12Make encoding of diameter_avp records more efficientAnders Svensson
Prepend the header in a single step. Before: {[{{diameter_codec,pack_avp,1}, 7000, 126.074, 51.058}], { {diameter_codec,pack_avp,2}, 7000, 126.074, 51.058}, % [{{diameter_codec,pack_avp,5}, 7000, 51.144, 25.758}, {{diameter_codec,pad,2}, 7000, 23.844, 23.570}, {suspend, 1, 0.028, 0.000}]}. After: {[{{diameter_codec,pack_avp,1}, 7000, 78.563, 26.986}], { {diameter_codec,pack_avp,2}, 7000, 78.563, 26.986}, % [{{diameter_codec,pack_avp,6}, 7000, 51.459, 26.381}, {suspend, 4, 0.118, 0.000}]}.
2017-06-12Replace slow binary comprehensionsAnders Svensson
Which appears to be about an order of magnitude slower than just creating a binary of the desired size.
2017-06-12Decode message header in a single matchAnders Svensson
2017-06-12Simplify missing AVP detectionAnders Svensson
By using the existing '#get-'/1 in generated dictionary modules to retrieve fields and values at the same time. Before: {[{{diameter_gen_base_rfc6733,missing,3}, 1000, 211.722, 8.741}, {{diameter_gen_base_rfc6733,'-missing/3-lc$^0/1-0-',4},12000, 0.000, 95.764}], { {diameter_gen_base_rfc6733,'-missing/3-lc$^0/1-0-',4},13000, 211.722, 104.505}, % [{{diameter_gen_base_rfc6733,'#get-',2}, 12000, 49.917, 28.221}, {{diameter_gen_base_rfc6733,has_arity,2}, 12000, 31.811, 23.442}, {{diameter_gen_base_rfc6733,avp_arity,2}, 12000, 21.076, 20.975}, {garbage_collect, 457, 3.918, 3.918}, {suspend, 31, 0.495, 0.000}, {{diameter_gen_base_rfc6733,'-missing/3-lc$^0/1-0-',4},12000, 0.000, 95.764}]}. After: {[{{diameter_gen_base_rfc6733,missing,3}, 1000, 134.098, 2.402}, {{diameter_gen_base_rfc6733,'-missing/3-lc$^0/1-0-',3},13000, 0.000, 77.327}], { {diameter_gen_base_rfc6733,'-missing/3-lc$^0/1-0-',3},14000, 134.098, 79.729}, % [{{diameter_gen_base_rfc6733,has_arity,2}, 12000, 31.084, 22.913}, {{diameter_gen_base_rfc6733,avp_arity,2}, 12000, 20.526, 20.440}, {garbage_collect, 253, 2.504, 2.504}, {suspend, 17, 0.255, 0.000}, {{diameter_gen_base_rfc6733,'-missing/3-lc$^0/1-0-',3},13000, 0.000, 77.327}]}.
2017-06-12Use maps when detecting missing AVPsAnders Svensson
Instead of the slower sets. Bump application dependencies to 17.5, even though earlier versions may do fine.
2017-06-12Make AVP splitting more efficientAnders Svensson
Profiling with fprof showed this prior to this commit: {[{{diameter_codec,decode,3}, 1000, 231.122, 4.092}, {{diameter_codec,collect_avps,1}, 1000, 0.000, 3.929}], { {diameter_codec,collect_avps,1}, 2000, 231.122, 8.021}, % [{{diameter_codec,collect_avps,3}, 1000, 222.932, 11.644}, {garbage_collect, 19, 0.169, 0.169}, {{diameter_codec,collect_avps,1}, 1000, 0.000, 3.929}]}. {[{{diameter_codec,collect_avps,1}, 1000, 222.932, 11.644}, {{diameter_codec,collect_avps,3}, 7000, 0.000, 68.186}], { {diameter_codec,collect_avps,3}, 8000, 222.932, 79.830}, % [{{diameter_codec,split_avp,1}, 7000, 120.886, 72.382}, {{erlang,setelement,3}, 7000, 21.830, 21.830}, {garbage_collect, 48, 0.386, 0.386}, {{diameter_codec,collect_avps,3}, 7000, 0.000, 68.186}]}. Note the time consumed in split_avp/1 and erlang:setelement/3. This commit does more matching in one go, without intermediate results, giving this: {[{{diameter_codec,decode,3}, 1000, 42.512, 3.701}, {{diameter_codec,collect_avps,1}, 1000, 0.000, 3.594}], { {diameter_codec,collect_avps,1}, 2000, 42.512, 7.295}, % [{{diameter_codec,collect_avps,3}, 1000, 35.217, 4.577}, {{diameter_codec,collect_avps,1}, 1000, 0.000, 3.594}]}. {[{{diameter_codec,collect_avps,1}, 1000, 35.217, 4.577}, {{diameter_codec,collect_avps,3}, 7000, 0.000, 27.754}], { {diameter_codec,collect_avps,3}, 8000, 35.217, 32.331}, % [{garbage_collect, 262, 2.647, 2.647}, {suspend, 9, 0.239, 0.000}, {{diameter_codec,collect_avps,3}, 7000, 0.000, 27.754}]}.
2017-06-12Remove bloat from zero encodeAnders Svensson
Don't call a function when we know the result, and consistently return a binary.