I was hoping $(\'#childDiv2 .txtClass\') or $(\'#childDiv2 input.txtClass\') perform better when selecting
CSS Selectors are parsed from right to left. So your example
$('#childDiv2 .txtClass')
will take two actions to complete. First find all elements with class txtClass. Then check each element for being a child of the element with the id childDiv2.
$('.txtClass')
This selector will just take one action. Find all elements with class txtClass
Have a look at this article on css-tricks.com