Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
zetsin
(version: 0)
Comparing performance of:
Lodash merge with cloneDeep vs Lodash merge
Created:
2 years ago
by:
Registered User
Jump to the latest result
HTML Preparation code:
<script src='https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.17.5/lodash.min.js'></script>
Script Preparation code:
var o = { "enrichedDeal": { "deal": { "dmsTransactionId": "TCCZXISBU", "version": 17, "contract": { "contractGrossAmount": 999999999, "closeDate": "2024-04-26", "brokerFee": { "percent": 0.01 }, "sideRepresented": 0, "dealAgent": { "userId": "5fa08292f9ce7e000190963e", "teamId": "612e7cd0cd63980001e3f4ff", "amaId": "a0gK000000A01vxIAB", "amaCompassTeamId": "TTT00044071" }, "acceptanceDate": "2024-04-24" }, "listing": { "address": "12000 Ailanthus Dr", "city": "Pensacola", "state": "FL", "zipCode": "32506", "listingType": 2, "propertyType": 0, "listingPropertyType": "Sale - Co-op", "regionFeeConfig": { "newYorkVoucher": { "programApplicable": false } } }, "submitter": { "submittedBy": { "userId": "612e7caf0ff1570001bb9da2", "teamId": "612e7cd0cd63980001e3f4ff", "amaId": "a0gK000000A01xYIAR", "amaCompassTeamId": "TTT00044071" }, "timeMs": 1714036756149, "submitterNotes": { "note": "test1" } }, "status": 13, "creation": { "userId": "612e7caf0ff1570001bb9da2", "timeMs": 1714036756211 }, "lastModification": { "userId": "612e7caf0ff1570001bb9da2", "timeMs": 1714103404204, "impersonatorId": "5c587ea69474a810d03fd475" }, "commissionSplit": { "allocations": [ { "agent": { "userId": "5fa08292f9ce7e000190963e", "teamId": "612e7cd0cd63980001e3f4ff", "info": { "displayName": "Principal Florida", "email": "test3+thajcak@compass.com", "firstName": "Principal", "lastName": "Florida" }, "amaId": "a0gK000000A01vxIAB", "amaCompassTeamId": "TTT00044071", "status": "Agent", "role": "Principal", "customerSfId": "APF00087848" }, "commissionPercent": 100 } ], "isJuniorToAccessAllocation": true }, "dealType": 0, "dealPayment": {}, "accessLevel": 2, "nonGCIRecording": false, "externalIds": { "businessTrackerFolderId": "2421242", "dmsFolderId": "f_1717529" }, "regionalCdaType": 0 }, "agents": { "a0gK000000A01vxIAB": { "agentName": "Principal Florida", "teamName": "Test Team FL", "sensitivity": "No", "officeName": "Seagrove Beach", "market": "Florida", "subMarket": "Walton County", "nsOfficeLocation": 1089, "nsSubMarketSubsidiary": 11, "sfOfficeId": "a0e4N00000OE9mFQAT", "nsPrimaryVendorId": 1350560, "agentUserId": "5fa08292f9ce7e000190963e" }, "a0gK000000A01xYIAR": { "agentName": "Michael Principal", "teamName": "Test Team FL", "sensitivity": "No", "officeName": "Seagrove Beach", "market": "Florida", "subMarket": "Walton County", "nsOfficeLocation": 1089, "nsSubMarketSubsidiary": 11, "sfOfficeId": "a0e4N00000OE9mFQAT", "nsPrimaryVendorId": 1449506, "agentUserId": "612e7caf0ff1570001bb9da2" } }, "users": { "5c587ea69474a810d03fd475": { "displayName": "TEST 2 CLOSER", "email": "dctestprod2@compass.com", "firstName": "TEST 2", "lastName": "CLOSER" }, "612e7caf0ff1570001bb9da2": { "displayName": "Michael Principal", "email": "test-team-principal@compass.com", "firstName": "Michael", "lastName": "Principal" } }, "netsuiteEntities": { "1350560": { "netsuiteId": 1350560, "name": { "uniqueName": "Principal Florida - APF00087848" }, "email": "test3+thajcak@compass.com", "isInactive": false, "roles": [ { "type": 0, "subsidiaries": [ 11, 83 ] }, { "type": 1, "subsidiaries": [ 11 ], "vendorApprovalStatus": 5 } ], "lastModifiedTimestamp": 1672717270000 }, "1449506": { "netsuiteId": 1449506, "name": { "uniqueName": "Michael Principal" }, "email": "michael.principal@compass.com", "isInactive": false, "roles": [ { "type": 0, "subsidiaries": [ 11, 12, 13, 14, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 33, 43, 54, 67, 69, 70, 71, 74, 80, 82, 83, 107 ] }, { "type": 1, "subsidiaries": [ 11, 12, 13, 14, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 33, 43, 54, 67, 69, 70, 71, 74, 80, 82, 107 ], "vendorApprovalStatus": 3 } ], "lastModifiedTimestamp": 1714080014453, "netsuiteExternalId": "AMP00087857" } } }, "dmsDocuments": [ { "isRequiredToProcessCommission": true, "checklistItemName": "Residential Purchase Agreement" }, { "checklistItemId": 2000000001, "isRequiredToProcessCommission": false, "checklistItemName": "Referral - Referral Agreement", "checklistItemPurposeType": 1 } ], "disableSubmitToCommission": false, "calculationPreview": { "dealCommission": { "calculationError": { "errors": [ "Failed to calculate deal commissions due to: Failed to build CalculateCommissionRequest due to internal error" ] } } }, "agentCalculationPreview": { "commissionSummary": { "effectiveSplit": 90, "grossCommissionIncome": 99999.9999, "netCommissionIncome": 89999.99991, "totalCommission": 89999.99991, "compassOffTheGrossAllocation": { "percent": 10, "amount": 9999.99999 }, "allocationRemainder": { "offTheGrossAllocation": { "percent": 0, "amount": 0 }, "offTheNetAllocation": { "percent": 0, "amount": 0 } } }, "commissionSummaryByAmaId": { "a0gK000000A01vxIAB": { "effectiveSplit": 90, "allocation": { "offTheGrossAllocation": { "percent": 90, "amount": 89999.99991 }, "offTheNetAllocation": { "percent": 100, "amount": 89999.99991 } } } } } }
Tests:
Lodash merge with cloneDeep
const a = _.merge(_.cloneDeep(o), o)
Lodash merge
const a = _.merge({}, o, o)
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
Lodash merge with cloneDeep
Lodash merge
Fastest:
N/A
Slowest:
N/A
Latest run results:
Run details:
(Test run date:
2 years ago
)
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36
Browser/OS:
Chrome 124 on Mac OS X 10.15.7
View result in a separate tab
Embed
Embed Benchmark Result
Test name
Executions per second
Lodash merge with cloneDeep
19860.9 Ops/sec
Lodash merge
18535.7 Ops/sec
Autogenerated LLM Summary
(model
llama3.2:3b
, generated one year ago):
I'll provide a response based on the provided JSON data. The provided JSON appears to be a benchmarking result from a JavaScript performance test, specifically testing the Lodash library's `merge` function with and without `cloneDeep`. The test results are categorized into two tests: "Lodash merge with cloneDeep" and "Lodash merge". Here is a summary of the latest benchmark result: * **Test Name:** Lodash merge with cloneDeep + Executions per second: 19,086.888671875 (on a Mac OS X 10.15.7 system with Chrome 124) * **Test Name:** Lodash merge + Executions per second: 18,535.6953125 (on a Mac OS X 10.15.7 system with Chrome 124) These results indicate that the Lodash `merge` function with `cloneDeep` is slightly faster than without `cloneDeep`. However, the difference is relatively small, and the performance impact may be negligible in most use cases. If you'd like to know more about the data or provide additional context, feel free to ask!
Related benchmarks:
test Q
test Q
Compare objects
RFC vs JSON.stringify
Comments
Confirm delete:
Do you really want to delete benchmark?