Merge "Minor improvements for invoke-custom" am: bc8835fdc6 am: 7bb9b170d6
am: 26a359df0b

Change-Id: I95556a470ce512e093f7fbcf0a65800e9c7d53ed